My understanding of the MVC is as follows (incase it's horribly wrong, I am afterall new to it)
- Models are the things that interface with the database
- Views are the design/layout of the page
- Controllers are where everything starts and are essentially the page logic
I'm using CodeIgniter but I would hazard a guess it's not just limited to that or possibly even just to PHP frameworks.
Where do I put global classes?
I may have a model for Products and I then run a query that collects 20 products from the database. Do I now make 20 models or should I have a separate class for it, if the latter, where do I put this class (other controllers will need to use it too)