What's MVC all about? For sure at this time you are very curious about this. In short, MVC is an architectural pattern, a way of structuring our application. When you were reading the previous chapters you had a glance at it; remember when we explored the file structure? At that time we saw that CodeIgniter was divided into these folders (among others):
system
application
models
views
controllers
As you can see there is a folder for each of the words (MVC); let's see what we can put into them:
Models: The models represent our application data, be it in databases, in XML files or anywhere else. Also, interaction with databases is carried here. For example, models will allow us to fetch, modify, insert, and remove data from our database. All actions that require our application to talk to our database must be put in a model.
Views: Files placed here are responsible for showing our data to the visitors to our site, or users of our application. No programming logic...