Wednesday, December 12, 2007


I had started on a PHP MVC framework many months ago. I got it working but never released it to the public. I think it is finished enough to let some people try it out.

TinyMVC is quite possibly the smallest, fastest and featureless ;) MVC framework for PHP. It's a perfect starting point for your application if you are starting from scratch, and want to adhere to the MVC design principle. It uses PDO as the model by default. It requires PHP5.

TinyMVC does not require a template engine, it uses PHP as it's view layer. However, you are free to bolt on any template engine of your liking, and there is an example for Smarty in the docs.

To try out TinyMVC, go to (passwords have been removed.)

Read through all the documentation before you begin, it doesn't take but a few minutes. Let me know what you think. Feel free to report bugs. The framework is tiny (16k download), so they should be easy to find.


Unknown said...

ive been trying it out to display results from a database.

ive got it to to display search form, and print back data from mysql, but yeh i cant get paging working for results gathered.

im lost with how the framework works, can you give me a example of how i can load another php page? right now its posting it self after submission.

mohrt said...

TinyMVC doesn't handle any kind of pagination at the moment. It is up to you with PHP and PDO to make the pagination happen. You can make new pages by simply creating new methods within your controllers and then going to them with [controller]/[method] in the URL.