Have some cake…

On May 4, 2006 one of the projects that I had been watching made the announcement that it has finally made a 1.0 release. After a long incubation period, it’s finally here… and it ROCKS!

I have been keeping close watch on the [CakePHP][cakehome] project for quite some time now. Ever since all the hype and hoopla for [Ruby on Rails][rorhome] exploded on the Internet, I wanted to see a similar framework for PHP and that’s when I discovered CakePHP (which was still in version 0.10.x). RoR is good but there are a few barriers to entry for me with this framework:

  1. Not a lot of hosting providers that support RoR out of the box, most of them offer RoR as an installable option or “uppgrade” for extra $$$.
  2. Documentation for the framework is a bit dodgy in some areas, though it’s improving constantly.
  3. The tutorials seem to speak of older RoR versions and focus primarily on the “scaffolding” feature of the framework. Though I think this has been revised already.
  4. I have to force myself to learn Ruby, not necessarily a bad thing but I prefer to stick with what I already know for production projects.
  5. I have tried installing and configuring a running server (not using webrick) and even with FastCGI, it’s still not as fast as PHP. Performance is really important to me and it seems it requires way too much work to get RoR running as fast as my current PHP-based framework (also using the MVC-pattern).

With CakePHP, I get most of what RoR currently offers without having to go through extra lengths that I had to go through with RoR to “just get things working”.

I like the fact that the CakePHP docs are honest in admitting that the scaffolding feature, while impressive during demos, are not really meant to be used in production work. RoR seems to push the scaffolding feature as one of their main selling points, which has led some newbie users into thinking that it was suited for production apps. From the CakePHP manual:

Cake’s scaffolding is pretty cool

So cool that you’ll want to use it in production apps. Now, we think its cool, too, but please realize that scaffolding is… well… just scaffolding. Its a bunch of stuff you throw up real quick during the beginning of a project in order to get started. It isn’t meant to be completely flexible. So, if you find yourself really wanting to customize your logic and your views, its time to pull your scaffolding down in order to write some code.

I tried out the [Blog Tutorial][cakeblog] and in less than 15 minutes I was able to finish it with everything working exactly as advertised.

It’s interesting to see what CakePHP-based applications others will come up with in the next few months. Personally, I am planning to rework my existing CMS framework to use CakePHP. I think it will be worth the effort, as it was certainly worth the wait for the 1.0 release.

[cakehome]: http://www.cakephp.org/ “CakePHP Home” [rorhome]: http://www.rubyonrails.org/ “Ruby on Rails Home” [cakeblog]: http://manual.cakephp.org/chapter/17 “CakePHP Blog Tutorial”

Leave a Reply

Comments are moderated by the administrator. If this is your first time posting a comment, your comment will go to a moderation queue and it may take a while for your comment to appear. Or it may get deleted.