CakePHP – Simple User Registration

After doing some initial readings on different PHP frameworks, including CakePHP, CodeIgniter, Symphony, Zend. I’m digging deeper into CakePHP with an open eyes for fresh ideas and other developments. To start, CakePHP is slow, quite slow (backed up by Rasmus’s benchmark at froscon). It also has not taken advantage of more object-oriented syntax and methods. That said, there are many neat ideas in CakePHP that we can learn to incorporate into our in-house high performance framework (but with less features and automagic).

Framework Performance

To those who says that “slow frameworks is acceptable or understandable”: good framework scales both in term of performance and functionality. It should be easily extensible from its tiny core. Software that does not use any framework cannot scale to provide more functionality and can offer good performance only at a simple task. Enough rants, let’s get dirty.

First App

This is a simple user registration. Cake does have its way of doing things and you might or might not like it. I’m not a big fan of $validate, $uses, and such. I do hope CakePHP will use more PHP5 and OOP the sooner the better since it’s a good framework.

User Model

User Controller

View – register.ctp


Posted

in

, ,

by

Tags:

Comments

Leave a Reply

Your email address will not be published. Required fields are marked *