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.
PayPal has fixed a serious vulnerability in its back-end management system that could have allowed...
Android is better than ever, but it's still not perfect. These are the things we wish were included in...
MIT researchers have found a way to transfer wireless data using a smartphone at a speed about three...
Going back to school? Here are some of the best laptop backpacks for every situation, whether you're...
You, of course, need to know your product and how it is built to market it. However, columnist Rob...
There are now 200 companies standing behind Privacy Shield, the framework agreement allowing businesses...
In the wake of continued security problems, NASA's CIO is sending a no-confidence signal to Hewlett...