Last post pretty much said it all. One of the traps of any Design Pattern in PHP is that you may end up with the impression there is a "single best way" to implement it. For simple patterns that's true, for something like MVC its not (regardless of what certain individuals - not on this forum - would claim).
MVC has 3 to 4 components:
- Controller (whatever handles input and output)
- Model (Business Logic; and possibly Data Access if not separated)
- View (lets be very simple and call it Smarty, or Savant, or whatever TE you use)
- Data Access (optional - but generally useful)
My own current "framework", a loosely used term in this case follows the following flow.
1. I have a index.php, or other, which implements a Front Controller (a single point of entry, which centralises common tasks, and is ultimately responsible for handling input Request and output Response).
2. I have a RequestMapper class, which maps a GET or POST variable to a specific Action/Command
3. I have multiple Action/Command classes, e.g. DisplayIndex, SaveUser, NewCart - usually action (not page) based
4. Commands use BusinessLogic and DataAccess classes to perform logical work, DB reads/writes
5. I have a View layer using Smarty or Savant, templates, etc.
A simple example.
I call "index.php?action=show:user&uid=4". This maps to the ShowUserCommand class. The class uses a simpel data access class, e.g. UserDB to look up the user id, and fetch the data. The command class will also assign this data to the view layer - your typical $tpl->assign() calls like Smarty uses. Though usually separate, you could also specify the template here (I tend towards separation so I can easily switch template engines...).
The Front Controller may call upon the View layer to display content from the parsed template.
This is one way of doing MVC - I have lots of other pieces of course, but these are largely marginal extras outside the core MVC pattern itself (i.e. security stuff, request and response class wrappers, etc. - optional though recommended).
Its not perfect - but one OS app I have which does use this type of MVC is a game I work on:
http://www.quantum-star.com/devsite/phpbb - if you download, peep inside /system/ and try the installer. Its a work in progress but its small enough to quickly read the code.