Presentation is loading. Please wait.

Presentation is loading. Please wait.

THE PHP FRAMEWORK FOR WEB ARTISANS. What is Laravel? Developed by Taylor Otwell Web application framework Follows MVC design pattern Expressive syntax.

Similar presentations


Presentation on theme: "THE PHP FRAMEWORK FOR WEB ARTISANS. What is Laravel? Developed by Taylor Otwell Web application framework Follows MVC design pattern Expressive syntax."— Presentation transcript:

1 THE PHP FRAMEWORK FOR WEB ARTISANS

2 What is Laravel? Developed by Taylor Otwell Web application framework Follows MVC design pattern Expressive syntax

3 Why use Laravel Elegant syntax Utilizes the latest PHP features Well documented CLI Tools Eloquent ORM Fun to develop with

4 Closures Introduced in PHP 5.3 Anonymous functions Route::get(‘login’, function() { return View::make(‘users/login’); });

5 The Syntactic Sugar Easy to understand Expressiveness and elegance Auth::check() Input::get() User::all()

6 The MVC Layers Eloquent ORM Blade Engine Controller

7 Eloquent ORM Easy to use class Feed extends Eloquent { public function user() { return $this->belongsTo('User'); } public function moment() { return $this->created_at->diffForHumans(); }

8 Eloquent ORM Example queries: Book::all() Book::find(1) Book::where(‘name’, ‘=‘, ‘John Doe’) Insert / Update $b = new Book(); $b->title = ‘Intro to Laravel’; $b->description = ‘This book rocks’; $b->save; $b = Book::find(2); $b->title = ‘Advanced Laravel’; $b->save();

9 Eloquent ORM Relationship mapping public function user() { return $this->belongsTo(‘Author’, ‘authro_id’); {

10 Blade Engine Stock templating engine for laravel Supports template inheritance and sections @yield('page_title') Some text @yield('content')

11 Blade Engine @extends(‘layout’) @section(‘page title’, ‘Test Page’) @section(‘content’) Hello user! @stop

12 Bootstrap The most popular front-end framework for developing responsive, mobile first projects on the web.


Download ppt "THE PHP FRAMEWORK FOR WEB ARTISANS. What is Laravel? Developed by Taylor Otwell Web application framework Follows MVC design pattern Expressive syntax."

Similar presentations


Ads by Google