While developing a CakePHP application and debug value set to greater than 0(zero) (development mode) we may want to show our Ajax results clean i.e. without debug information (in form of SQL log etc.) attached to it.
Category: CakePHP
What do you hate about CakePHP?
After looking at an interesting Google group topic Poll: what do you hate about CakePHP? i have tried to sum up the facts which people reasoned for hating/disliking CakePHP. Please be noted that all the facts listed here are based…
Useful string manipulation helpers in CakePHP
CakePHP comes with a bunch of useful helpers and components which provide handy tools for processing and manipulating data. These helpers are not only the valuable assets for the a framework user, but can be of great help to someone…
getid3 component for cakephp
What is getID3? getID3() is an open-source, cross-platform software library for the PHP language written by James Heinrich and Allan Hansen. getID3() can extract information from multimedia file formats: audio, video and images in various formats. Information extracted includes playtime,…
Passed arguments routing and custom ajax pagination url in cakephp
While working in my recent “charity project” i had to list all charities found in a particular region or state. I created a regions_controller and an index function in it to fetch and set records and index.ctp as a view…
An alternate to paginator counter showing page in cakephp
An ordinary yet useful piece of hack to the way the cakephp pagination’s pages “showing page” parameter is displayed. As default, we are used to use $paginator->counter() method which gives us a counter string for the paged result set like…
Cakephp important facts you must know – Part 2
CakePHP comes with a bunch of useful helpers and components which provide user handy tools to process and manipulate data. These helpers are not only the valuable assets for the framework user, but can be of great help to someone…
Error handling in cakephp
Error handling in CakePHP is pretty simple and straight forward. While developing in CakePHP with debug value set to > 0 (Configure::write(‘debug’, 1); in app/config/core.php) you might have encountered error messages something similar to this:
How to use multiple validation rule sets per model in cakephp
As default we have single var $validate rule set in the model class which is triggered on each save() method call while saving form data. This is quite logical and sufficient for single form fields to validate but what if…
How to apply search filters in cakephp ajax pagination
Sometimes we need to filter records via custom query while using ajax pagination in a cakephp application. An easy way to achieve this is to store query in a session varibale and to check it whenever an ajax call is…