Codeigniter Model Tutorial

Codeigniter Model

So far we’ve looked at Controllers and Views in the MVC or Model View Controller paradigm. With just those two facets of MVC you can actually build some pretty cool, albeit simple, applications that have basic logic and features. Now we come to the Model. We save the best for last! The Model is really the workhorse in your MVC website. Most people will try to keep their controllers and views skinny while the model becomes fat.…

Learning About Views in Model View Controller


In the MVC structure we separate out the logic from presentation. The controller which we explained in a prior blog post handles the processing and incoming http requests. The controller is the boss sort to speak. When you make a request to the website, that controller starts making some decisions. It asks, “What is it, that this user needs or wants?”. You tell the controller this, whether knowingly or not, based on the actual URL that you are requesting.…

What are Codeigniter Sessions

Codeigniter comes with a great session class. Sessions in any programming language are what give you the ability to keep track of a user’s state while also tracking their activity. In Codeigniter this session information is stored as a cookie. You also have the option to store this session in a database. That is up to you.

codeigniter sessions

How do I start a session

The great thing about using a framework is that many things are done for you.…

Controllers in Codeigniter


The MVC pattern is popular in all languages and in particular PHP. MVC is the model, view, controller paradigm in programming. We’ll take a look at controllers now, as they are the portion of the MVC approach that handles incoming HTTP requests, and direct your application to take action. Controllers are used in all flavors of frameworks, and each has their own attributes. For this demonstration, we’ll focus on codeigniter.…