Skip to content

Instantly share code, notes, and snippets.

View danieluyo's full-sized avatar

Josafat Daniel Salcedo Sambrano danieluyo

  • CS Group
  • México
View GitHub Profile
$username = '';
$password = '';
$strSql = "SELECT user_pass FROM wp_users WHERE user_login = '$username'";
$result = mysql_query($strSql);
$row = mysql_fetch_array($result);
$encpass = $row['user_pass'];
if(!is_null($encpass)) {
include('wp-includes/class-phpass.php');
<?php
$db = new mysqli('localhost', 'user', 'pass', 'demo');
if($db->connect_errno > 0){
die('No es posible conectar a la base de datos. [' . $db->connect_error . ']');
}
$sql = "SELECT * FROM example";
<?php
namespace App\Libreria\Cashier;
use Conekta\Conekta;
use Conekta\Customer;
use Conekta\Plan;
use Conekta\Order;
class Cashier {
@danieluyo
danieluyo / Laravel PHP7 LEMP AWS.md
Created April 19, 2017 18:26 — forked from santoshachari/Laravel PHP7 LEMP AWS.md
Laravel 5.x on Ubuntu 16.x, PHP 7.x, Nginx 1.9.x

#Steps to install latest Laravel, LEMP on AWS Ubuntu 16.4 version. This tutorial is the improvised verision of this tutorial on Digitalocean based on my experience.

Install PHP 7 on Ubuntu

Run the following commands in sequence.

sudo apt-get install -y language-pack-en-base
sudo LC_ALL=en_US.UTF-8 add-apt-repository ppa:ondrej/php
sudo apt-get update
sudo apt-get install zip unzip
@danieluyo
danieluyo / ConektaTestController.php
Last active December 16, 2018 22:37
Laravel Conekta Test
<?php
namespace App\Http\Controllers\Test;
use Illuminate\Http\Request;
use App\Http\Controllers\Controller;
use Conekta\Conekta;
use Conekta\Order;
use Conekta\Charge;