This is a guide for aligning images.
See the full Advanced Markdown doc for more tips and tricks
This is a guide for aligning images.
See the full Advanced Markdown doc for more tips and tricks
<?php | |
use Illuminate\Foundation\Testing\WithoutMiddleware; | |
use Illuminate\Foundation\Testing\DatabaseMigrations; | |
use Illuminate\Foundation\Testing\DatabaseTransactions; | |
class ExamplePassportTest extends \PassportTestCase | |
{ | |
use DatabaseTransactions; |
Code is clean if it can be understood easily – by everyone on the team. Clean code can be read and enhanced by a developer other than its original author. With understandability comes readability, changeability, extensibility and maintainability.
namespace App\Http\Middleware; | |
use Illuminate\Support\Facades\Log; | |
class LogAfterRequest { | |
public function handle($request, \Closure $next) | |
{ | |
return $next($request); | |
} |
reference: http://stackoverflow.com/questions/21820715/how-to-install-latest-version-of-git-on-centos-6-x-7-x | |
yum install http://opensource.wandisco.com/centos/7/git/x86_64/wandisco-git-release-7-2.noarch.rpm | |
yum update git |
<?php // /app/Http/Middleware/Cors.php | |
namespace App\Http\Middleware; | |
use Closure; | |
class Cors { | |
public function handle($request, Closure $next) | |
{ | |
return $next($request) |
APP_ENV=local | |
APP_DEBUG=true | |
APP_KEY=SomeRandomKey!!! | |
DB_CONNECTION=mysql | |
DB_HOST=localhost | |
DB_PORT=3306 | |
DB_DATABASE=homestead | |
DB_USERNAME=homestead | |
DB_PASSWORD=secret |
<?php | |
function get_youtube_channel_ID($url){ | |
$html = file_get_contents($url); | |
preg_match("'<meta itemprop=\"channelId\" content=\"(.*?)\"'si", $html, $match); | |
if($match && $match[1]); | |
return $match[1]; | |
} |
// data from https://gist.github.com/andyj/7108917 | |
$array = [ | |
'44' => 'UK (+44)', | |
'1' => 'USA (+1)', | |
'213' => 'Algeria (+213)', | |
'376' => 'Andorra (+376)', | |
'244' => 'Angola (+244)', | |
'1264' => 'Anguilla (+1264)', | |
'1268' => 'Antigua & Barbuda (+1268)', |