Stable Release in branch 1.3
1.3.21
Released 31 Oct 2015
(10 years ago)
SoftwareCakePHP
Version1.3
Status
End of life
Supported
PHP versions
PHP 4-5
Initial release1.3.0
25 Apr 2010
(16 years ago)
Latest release1.3.21
31 Oct 2015
(10 years ago)
End of security fixesUnavailable
Release noteshttps://github.com/cakephp/cakephp/releases/tag/1.3.21
Source codehttps://github.com/cakephp/cakephp/tree/1.3.21
Documentationhttps://book.cakephp.org/1/en/index.html
Downloadhttps://book.cakephp.org/1/en/installation.html
CakePHP 1.3 ReleasesView full list

What Is New in CakePHP 1.3

CakePHP 1.3 is a significant update focused on modernizing the framework's core, improving data handling, and refining the developer experience. It introduces new conventions, more powerful tools for models and controllers, and lays the groundwork for future development. This release emphasizes cleaner code and more flexible application architecture.

Category Key Changes
New Features New Console Shells, Behaviors, and Helper classes. Introduction of the Set utility and Sanitize class.
Model Layer Enhanced Model::find() methods, new binding system, and improved data validation.
View & Helpers New Html, Form, and Js helpers with improved functionality and security.
Controller & Components New components like RequestHandler and Security. Improved scaffolding and redirects.
Core & Performance New class loading (App::import()), improved caching, and better overall speed.
Deprecated / Removed Legacy functions and patterns are deprecated in favor of new APIs and conventions.

How is data finding and validation improved?

The Model layer gets a major overhaul. The new Model::find() methods offer a more consistent and powerful API for crafting queries. You can now use 'first', 'count', 'list', 'all', and 'neighbors' as find types, which makes code more readable and expressive.

In practice, this means less manual SQL and cleaner model logic. The validation system is also more robust, allowing for complex rule sets and better integration with the Form helper for automatic client-side rules.

Example of new find types:

// Find a count of published articles
$this->Article->find('count', array('conditions' => array('published' => true)));

// Find a list for dropdowns
$this->Article->find('list', array('fields' => array('id', 'title')));

What new tools are available for views and forms?

Views become more powerful with a suite of rebuilt helpers. The new Html, Form, and Js helpers provide safer, more concise methods for generating markup and handling dynamic content. The Form helper, in particular, integrates tightly with model validation to output HTML5-compatible form elements.

This matters because it reduces boilerplate code and helps prevent common security issues like XSS. The helpers automatically handle things like field naming and CSRF protection when used with the Security component.

New helper usage:

// Old way (deprecated)
echo $html->link(...);

// New way in 1.3
echo $this->Html->link(...);

How does the new class loading work?

CakePHP 1.3 introduces App::import() as a replacement for the older uses() function and various vendor() methods. This centralizes and streamlines how classes are loaded from within the app, plugins, and vendors.

The new loader is more intelligent and follows consistent naming conventions. It reduces the need for manual file includes and helps keep your code compliant with the framework's evolving structure. This change is a foundational step towards better autoloading in future versions.

What should I know about deprecated features?

This release marks many older functions and patterns as deprecated. Key areas include the old $html and $javascript helper variables, the original Model->findAll() methods, and certain configuration settings.

While deprecated features still work, they will trigger notices in the debug log. The goal is to give developers a clear migration path to the new APIs. Updating your code now ensures compatibility with future 1.3.x releases and makes the eventual jump to CakePHP 2.0 much smoother.

FAQ

Is CakePHP 1.3 a major breaking change from 1.2?
No, it's a backward-compatible evolution. Your 1.2 applications should run, but you'll see deprecation notices for old APIs. The core team encourages updating code to use the new methods for better performance and security.

What is the single most important change to adopt?
Start using the new Model::find() types ('first', 'count', 'list', etc.) immediately. They are more consistent and powerful, and the old findAllBy style methods are on the path to deprecation.

How does the new Sanitize class help?
It provides a centralized, more reliable way to clean user data for different contexts (HTML, SQL, arrays). This is a security enhancement that replaces ad-hoc cleaning scattered throughout applications.

Are there changes to how plugins work?
Yes, plugin loading and class location is more standardized. Using App::import() is key. This improves reliability and paves the way for plugins to be more self-contained.

Why was the Set utility introduced?
Manipulating complex arrays (like nested data from finds) is very common in CakePHP. The Set utility provides a fast, uniform set of functions for this, replacing inconsistent user-land code and improving performance.

Releases In Branch 1.3

VersionRelease date
1.3.2131 Oct 2015
(10 years ago)
1.3.2020 Jul 2014
(12 years ago)
1.3.1914 Jun 2014
(12 years ago)
1.3.1828 Apr 2014
(12 years ago)
1.3.1724 Jun 2013
(13 years ago)
1.3.1629 Apr 2013
(13 years ago)
1.3.1525 Mar 2012
(14 years ago)
1.3.1428 Dec 2011
(14 years ago)
1.3.1315 Oct 2011
(14 years ago)
1.3.1218 Sep 2011
(14 years ago)
1.3.1126 Jul 2011
(15 years ago)
1.3.1030 May 2011
(15 years ago)
1.3.920 May 2011
(15 years ago)
1.3.820 Mar 2011
(15 years ago)
1.3.719 Jan 2011
(15 years ago)
1.3.613 Nov 2010
(15 years ago)
1.3.524 Oct 2010
(15 years ago)
1.3.412 Sep 2010
(15 years ago)
1.3.318 Jul 2010
(16 years ago)
1.3.207 Jun 2010
(16 years ago)
1.3.129 May 2010
(16 years ago)
1.3.025 Apr 2010
(16 years ago)
1.3.0-RC412 Apr 2010
(16 years ago)
1.3.0-RC328 Mar 2010
(16 years ago)
1.3.0-RC214 Mar 2010
(16 years ago)
1.3.0-RC128 Feb 2010
(16 years ago)
1.3.0-beta16 Jan 2010
(16 years ago)
1.3.0-alpha09 Dec 2009
(16 years ago)