Kohana or CodeIgniter or CakePHP?

I am going to start on a small system for internal use and I wanted to re-think my choice of CodeIgniter because it does not have templates or ORM. Guess what, I landed with KohanaPHP. It sounds very tempting that a new MVC Framework based on CodeIgniter with new features (especially ORM) is here but the documentation is really really poor.

I tried googling for a book or tutorial and I was really disappointed to have found none. I tried Amazon.com for a book but no books. Looks like I have landed in some weird space that might be good looking but I need to get my hands dirty in the code to learn it and at the end of the day, it may seem that I have lost a lot of hours on this new Framework. Lets give it a try!

Update: As of today (28th July, 2010), I am working on YII, its good, powerful and blazing fast. It has all the feature of CakePHP too.

CodeIgniter or CakePHP? can’t decide

Can’t decide between CodeIgniter or CakePHP for my personal project. CodeIgniter is faster in terms of performance but development is slow, CakePHP‘s cake-bake makes development faster but its performance is not good. My problem is that I need both. I want it at best performance since I will be handling millions even billions of domain records AND I cannot spend more time developing my own system.

Any ideas?

Getting Started on CodeIgniter, the lightening fast PHP Framework

Today, I have started on CodeIgniter, one of the powerful PHP frameworks recommended by Rasmus Lerdorf

CodeIgniter is most often noted for its speed when compared to other PHP frameworks. In a critical take on PHP frameworks in general, PHP creator Rasmus Lerdorf spoke at frOSCon in August 2008, noting that he liked CodeIgniter “because it is faster, lighter and the least like a framework”.

Read more about it here.

So far what I can tell you is that it really is FAST. I have been coding in CakePHP and Zend Framework, but this framework is very fast. Truely speaking I did not felt any difference using it.

I will keep posting about my experience of CodeIgniter.

Using CakePHP’s Bake on Linux

If you want to use CakePHP’s bake tool on Linux command line (like I have development environment on Linux) then you can ssh to your linux box as shown in the screen shot below

Linux Console

Second, you can execute the cake bake command in the following manner

./cake/console/cake bake

as shown in the picture below
Linux Console

CakePHP – link / include JavaScript files in layouts

Create (or modify the) file


add this code

class AppController extends Controller {
	var $helpers = array('Html', 'Form', 'Javascript');

CakePHP 1.2 allows you to define a reference to a Javascript file which is then added to the head section of the generated code. For this purpose the variable $scripts_for_layout has to be added to the layout:

	< ?php echo $scripts_for_layout; ?>

In the view you can now link to the Javascript file with:

$javascript->link('script.js', false);
// OR you can simply use $javascript->link('script.js');