Regarding your opinion on routing at PHP level, I disagree.
Apache may be fast to perform the routing based on mod_rewrite, but hard for people to write the htaccess rules. PHP is much easier and if you still strongly feel the neeed for faster performance route why not a C implementation like Pux can be introduced ?
It can't be simpler than this. Requests are directed to the scripts that run your controllers. There is no need for front controllers to look at the URLs and match them against any of the controller URL patterns you need to match.
I may end up writing an article about this because you framework fans always assume the framework you are in love with is the best for everything. Consider the fact that you may not know all the best techniques.
Manuel Lemos - 2014-02-12 06:27:06 - In reply to message 3 from Hari K T
What I mean is that if you put in your Apache configuration something like this, you will be telling that all requests to URLs that start with /blog/ will be handled by a PHP script named blog. In that PHP script named blog you just call your blog controller classes. No front controllers or mod_rewrite are needed.
Manuel Lemos - 2014-02-12 06:51:30 - In reply to message 5 from Hari K T
That is the thing Rasmus was trying to make people pay more attention.
If you are using a certain setup, Apache for instance, it does not make sense to optimize for a different setup that is not what you are running.
If you are using MySQL, why are you checking on every request the type of database you are using? It won't change, so optimize for it.
Anyway, if you change to nginx one day, I don't know if there is anything like SetHandler for nginx, but in the worst case you can use their equivalent for mod_rewrite and make your request to /blog/* be handled as if they were going to /blog.php/* .