2015. március 2., hétfő

Laravel snippets

 


Laravel – get last query:


$queries = DB::getQueryLog();

$last_query = end($queries);

var_dump($last_query);
Echo the version of the current Laravel version in PHP:

$laravel = app();

echo $version = $laravel::VERSION;


 



Laravel snippets