10 => Models, Views & Controllers
This blog will cover the basics of what the MVC pattern is and how Laravel implements the pattern. The beginning of this entry will provide a high level overview of the pattern and will dive into some helpful functionality that Laravel provides that makes using the pattern easier. Model The applications models contain the applications main business logic. They are the main part of the application. The controllers delegate jobs to models and return views to the client. Models can be created using the artisan command php artisan make:model [name] By including the -c flag the previous command will make a Controller for that given model with CRUD methods scaffolded. php artisan make:model [name] -c The applications models can be found in app_route / app / models View The view is what the user interacts with, in the case of web application it is the HTML that is served to the client. Views are served to the client ...