CakePHP combines easy installation with command-line tools that jump-start development
CakePHP, a product of the Cake Foundation, successfully walks the line between large frameworks (such as Zend) and small frameworks (such as Lithium). CakePHP's documentation claims that the framework requires no configuration. The CakePHP website gushes, "Set up the database and let the magic begin." This is a bit colorful, but not too far from the truth. The framework also features excellent command-line tools that dramatically reduce the time required to build an application. The current stable release, Version 1.2.9, requires at least PHP 4.3.2.
As with other frameworks, CakePHP defines a strict directory structure, with equally strict rules regarding which files go in which subdirectory. This is referred to as "convention over configuration" and is in keeping with the framework's "no configuration" claims. You don't modify a configuration file to specify the location and function of files, classes, or methods; rather, you place specific elements in predetermined locations within the project. For example, all the library code is kept in the /cake subfolder of an application directory, and documentation expressly states that you must swear an oath not to modify the files in that directory. The directory structure also distinguishes between first-party libraries and third-party libraries, which helps you keep your corporate libraries separate from those acquired from the outside.
The convention over configuration principle carries through to framework entity names. Model classnames must be singular and camel-cased. For example, a model that manages music albums might be represented by a class named MusicAlbum. Table names corresponding to CakePHP models are plural and underscored, so our table for the MusicAlbum model would be music_albums. CakePHP even provides a utility library for pluralizing names to assist in the process.
This story, "Fabulous PHP frameworks: CakePHP" was originally published by InfoWorld.
If you enjoy a sharply-worded insult, read on. This slideshow’s for you.
Cool new features on the horizon include power-sipping chips and the Hello authentication technology.
In a few weeks, the long-awared Samsung Galaxy S6 will go on sale. Here are seven things you need to...
The fact that our eyes can't even tell what color that dress is? That's great for Oculus.
The attacks were aimed at two GitHub-hosted projects fighting Chinese censorship
Carriers and consumers would get access to a fat frequency band used mostly by government today
Intel is in talks to acquire Altera, according to a report in The Wall Street Journal