New MVC Frameworks, my old friend PHP

Ok it’s been a while since my last post..

So what keeps me busy in these days, mostly design patterns, mvc frameworks, and of course PHP.

I make lots of research (again 🙂 ) on php mvc frameworks, like yii, kohana 3, codeigniter, cake, symfony and very basic ones.

After lots of reading, benchmarking and testing with small projects, I chose Kohana 3 to learn and develop basic projects.

There are lots of reasons why I chose Kohana 3 and I’m gonna list most of them but, again, these are not facts, you should choose one for your needs!

Firstly you should decide about design pattern that suits your project, it can be MVC or others. If you choose MVC for your project, then you can choose which MVC framework is best for you, you can even write your own. (maybe you should).

If you’ll use MVC design pattern and one of common PHP MVC framework, the first thing you should consider is php version.

If you will not use PHP 5 for some reason, (hosting etc.) (But I highly recommend that try to use PHP 5.3) you should go with codeigniter or cake. Because kohana 3 and yii framework support only php 5.

I made some very small websites using CodeIgniter and Cake, and I recommend CodeIgniter over Cake. There is not too much magic in codeigniter, it’s very easy to learn and easy to start.

If you have no restriction about PHP versions, you have more options, including kohana 3, yii, symfony 2.

symfony 2: It seems promising, according to their benchmark result, symfony 2 is very fast, but they are not recommending to use as a stable product yet. So I skipped this option and honestly it has more magic than I want.

yii: Yii is very fast, according to lots of comparisons between yii, kohana 2, zend and cake.

Unfortunately I couldn’t find a comparison between yii and kohana 3, still I guess it’s the fastest MVC framework for PHP right now.

So why I didn’t use it? The reason is, it makes me feel like a rails for PHP. I think yii has the most magic among PHP MVC frameworks.

kohana 3: Kohana is a lightweight, flexible HMVC framework.

It is very easy to install and get started with. If you don’t like too much magic functions like me, the best option would be kohana 3.

Its biggest disadvantage is documentation. Between these frameworks, kohana has the least documentation and it’s really important when you start learning something new.

Here is a good list of learning Kohana websites: learning kohana.

Especially Unofficial Kohana 3.0 Wiki helped me a lot.

To sum up, you should first choose design pattern for your app, and if it’ll be MVC, start with one you feel comfortable.

P.S 1: Kohana 3.1 is released before make this post public. If you’ll make a fresh start, use latest stable kohana.

P.S 2: If you wanna take a look my kohana 3.1 app, here is qamini, Q & A system powered by Kohana 3.1. You’ll see the usage of ORM, OAuth, Unittest, Ajax and more..

See you!


Tags: , , , , , , , , ,

Comments: 3

Leave a reply »

  • Take a glance at, would appreciate your thoughts.

  • peter


    I cloned qamini with git, configured it according to the readme, but when I run

    I get

    ErrorException [ Warning ]: session_start() [function.session-start]: Function spl_autoload_call() hasn’t defined the class it was called for

    Any idea why? (I am new to Kohana)

    • Hi,

      firstly apologize for the really late answer, blog spam filter misjudge..
      Anyway, it is probably because of PHP version issue.

  • Leave a Reply
    Your gravatar
    Your Name