Laravel is one of the best PHP Framework. Laravel is a web application framework with expressive, elegant syntax. We believe development must be an enjoyable, creative experience to be truly fulfilling. Laravel attempts to take the pain out of development by easing common tasks used in the majority of web projects, such as authentication, routing, sessions, and caching.
Commands:
Download : composer create-project laravel/laravel {directory} "5.4.*"
Download ex: composer create-project laravel/laravel directory_name "5.4.*"
To start service, run this command on project root folder:
php artisan serve
To make controller file by command:
// TestController is contoller name.
php artisan make:controller TestController
To create user login/registration form:
php artisan make:auth
To create table in database:
php artisan migrate
To make the model by the command:
// Candidate is model name created under database > migrations folder.
php artisan make:model Candidate -m
To generate application key:
php artisan key:generate
Replace the
php artisan app:name
Start Maintenance Mode:
php artisan down
Stop Maintenance Mode:
php artisan up
Middleware can be created by executing the following command −
php artisan make:middleware
ex: php artisan make:middleware AgeMiddleware
Terminable Middleware:
php artisan make:middleware TerminateMiddleware
Enjoy!!