Upgrade to Pro — share decks privately, control downloads, hide ads and more …

What are you expecting from next version of Laravel?

What are you expecting from next version of Laravel?

New features from Laravel PHP Framework 5.1

phpXperts meetup-01 presentation

778ab3e12267bd05ff7bac226fb2027d?s=128

Nuruzzaman Milon

May 30, 2015
Tweet

More Decks by Nuruzzaman Milon

Other Decks in Programming

Transcript

  1. None
  2. None
  3. None
  4. None
  5. None
  6. None
  7. None
  8. None
  9. @extends('layouts.master') @inject('stats', 'App\StatisticsService') <div> <span>Total Customer:</span> {{ $stats->getCustomerCount() }} </div>

  10. None
  11. @server(['homestead' => '127.0.0.1']) @task('git') git init git commit -am 'Initial

    Commit' @endtask @macro('commit') git @endmacro
  12. > envoy run commit > composer global update

  13. None
  14. class VerifyRoles{ public function handle($request, $next, $role = null){ //your

    logic goes here } } Route::get('/dashboard', ['middleware' => 'role:admin', function(){ return view('dashboard'); } ]);
  15. None
  16. None
  17. None
  18. <?php namespace App\Http\Middleware; use Illuminate\Foundation\Http\Middleware\VerifyCsrfToken as BaseVerifier; class VerifyCsrfToken as

    BaseVerifier{ protected $except = [ '/payment/callback', '/webhook/*' ]; }
  19. None
  20. // file: database/factories/ModelFactory.php $factory->define('App\User', function ($faker) { return [ 'name'

    => $faker->name, 'email' => $faker->email, 'password' => str_random(10), 'remember_token' => str_random(10), ]; });
  21. None
  22. None
  23. None