template

Elements

Elements are reusable blocks of code you can create once and use in multiple Views of your site, making it easier to make changes in a single location instead of searching for all the occurrences of the same code.

For ease of access I create a common login/logout block to display on all the pages of my applications.

Controller and Views

At this point, if you browse to your application, for example http://localhost/tutorial/users/, you'll see an error indicating that your UsersController cannot be found, and the debug output gives you a suggestion of a bare-bones framework for the controller. You can copy and paste that code or type it by hand, but that's exactly where we'll start for your Users Controller to retrieve data from the Model.