Hacker News new | past | comments | ask | show | jobs | submit login

> Fast and clean template engine

Is PHP not already a template language?

The whole idea of PHP frameworks always confused me. Why do I need a router when I can simply add new files at the routes I want?




You're right, it is.

The advantage of a router is basically: please always execute this code (auth, db connection, logging, session, rate limiting, csrf protection) before running the actual code for pages that will be rendered.

Or you could also just keep using normal page.php files and possibly include a boot.php at the top of the pages to achieve the same. But then you don't get pretty URLs unless you're doing some server URL rewriting.

Come to think of it, routers require URL rewriting too.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: