CakePHP vs Ruby on Rails. And the battle continues…
- Posted by Tengku Zahasman on September 12th, 2007 filed in Web Programming, PHP, CakePHP, Web App Development, Thoughts
- 6 Comments »
- (2,317 Views)
When the funny guys at RailsEnvy.com published a video comparing RubyOnRails with PHP, they received a lot of criticisms from the viewers for making an unfair comparison between jets and cars, when they should be comparing jets with jets. The viewers were right. PHP is a language. RubyOnRails is a framework. If they wanted to compare RubyOnRails with something, they should be comparing it with another “framework” instead of a language.
So here is the video commercial I’m talking about (I find these guys to be very entertaining):
Soon after they realized their mistake, they created another video comparing CakePHP with RubyOnRails to be fair to the PHP community. While it’s not really a “comparison”, I still find it so hilarious. Check it out 
LoL. These guys should seriously consider becoming movie actors
Anyway, it’s true that CakePHP functions the same way RoR works, and I don’t think any Cake Bakers would deny that Cake was initially designed to work like RoR, only in PHP. In fact, there were times when CakePHP used to be nicknamed as “PHP on Rails”. But the way I see it, CakePHP is starting to move on its own way now and becoming more independent the more it grows. Bravo to the CakePHP developers!
CakePHP vs Ruby On Rails. Which is the better framework?
It’s not for me to judge since I never fiddled around much with RubyOnRails before.. at least not as seriously.
What I do know is that both of them follow the MVC design pattern. Both adhere to the “Convention over Configuration” philosophy and Don’t Repeat Yourself (DRY) concept. Both of them also support AJAX. They have an almost identical directory structure. They’re built with testing in mind. They are very OOP-like. They have their own shells for command-line interface stuffs. They both support caching. They support different databases (MySQL, PostgreSQL, etc…). And they’re both released under the MIT license.
The reason why I’m sticking with CakePHP instead of jumping into the RoR bandwagon is because I know I’m already fluent in PHP, so why would I want to learn a new language (Ruby) and a new framework (Rails) when I already have a very Rails-like framework written in PHP? If you strip off “Rails” from Ruby, you’ll realize that Ruby is just another programming language. Sometimes I keep wondering myself why some of those hardcore PHP-ers would migrate completely to RoR and go through the hassles of learning the new syntaxes & built-in functions of Ruby all over again when there’s Cake that does almost entirely the same thing. Even the 37signals guys (the brilliant minds behind RoR) uses PHP in many of their sites. Get real.
To set things straight, RubyOnRails is an awesome framework and I have nothing against it. CakePHP is also an awesome framework. I am no way saying that one is better than the other. They both have their own place and strengths in the web development scene. What I’m saying is unless you want to learn all the programming languages that exists out there, why not just stick with the language you’re currently strong at and use the available framework which works with your favorite language to build the applications of your dream. Save “learning a new language” for your next spare-time hobby. 
Neat slide on Cake 1.2
- Posted by Tengku Zahasman on September 9th, 2007 filed in PHP, CakePHP, Web App Development
- 1 Comment »
- (1,240 Views)
CakePHP 1.2 has never ceased to amaze me ever since I started my romantic journey with her. Even though it is still marked as in “Alpha” development stage, I find it to be too interesting that I have left the 1.1 branch for good. Cake 1.2 have so many useful functionalities, “bundled” components and that little useful touches which makes it so practical to use and so much easier to implement. In fact I am currently converting most of my existing apps (where some of them were written like spaghettis) into CakePHP for the past two weeks and I just love every minute of it.
Recently, gwoo (one of Cake’s developer if I’m not mistaken) gave a talk on the Orange Country PHP group regarding the ins and outs of CakePHP as well as the latest development on the 1.2 branch. Here are the slides that all Cake lovers should read (also available in PDF format here).
With all the cool new added features that Cake 1.2 has to offer, why would anyone needs to jump to another language/framework? 
The Computer Programmer
- Posted by Tengku Zahasman on September 5th, 2007 filed in Ramblings
- 11 Comments »
- (1,402 Views)
I’m pretty much a programmer, and jokes like this never fails to make me chuckle
:
Found at OffBeatEnough
A man was crossing a road one day when a frog called out to him and said, “If you kiss me, I’ll turn into a beautiful princess.” He bent over, picked up the frog, and put it in his pocket.
The frog spoke up again and said, “If you kiss me and turn me back into a beautiful princess, I will tell everyone how smart and brave you are and how you are my hero.” The man took the frog out of his pocket, smiled at it, and returned it to his pocket.
The frog spoke up again and said, “If you kiss me and turn me back into a beautiful princess, I will be your loving companion for an entire week.” The man took the frog out of his pocket, smiled at it, and returned it to his pocket.
The frog then cried out, “If you kiss me and turn me back into a princess, I’ll stay with you for a year and do ANYTHING you want.” Again the man took the frog out, smiled at it, and put it back into his pocket.
Finally, the frog asked, “What is the matter? I’ve told you I’m a beautiful princess, that I’ll stay with you for a year and do anything you want. Why won’t you kiss me?”
The man said, “Look, I’m a computer programmer. I don’t have time for a girlfriend, but a talking frog is cool.”

Programming is kind of an addictive activity (much like playing games) especially when you’re working on a cool function and you know you’re already half-way there. By the time you can see the light at the end of the tunnel, nothing can stop you and take your hands away from the keyboard. Not your girlfriend’s call, not your mom calling out for dinner from downstairs, not even the clock that already strikes 2AM. Your main mission: finish that code and make it dance!
Time management is very important for being a mentally and physically healthy programmer, because as a programmer, you’ll need to balance your social life and your non-social little hobby - programming. If you can’t manage this well, you will be left with no option but to choose either one. I believe every programmers will face this kind of dilemma every now and then in some part of their lives. Programmers who have a lover and who socialize around a lot kinda have this tiny wish that everyone will one day just vanish and leave him alone with their laptop so that they can have all the time to work on their projects without anyone making it such a big deal. On the other hand, programmers who have very little social life and who doesn’t have a romantic partner - although happy for being able to do what they love - do have that tiny wish to be loved by someone and “having a life” and being well accepted in the community.
Just some thoughts.. 







If I've provided some info that you find to be useful, don't hesitate to