Category Archives for Web Development

Add Your Own Validation in model On CakePHP

Update: Here is model file to download Download Code CakePHP has many validation rules that can make model data validation much easier. There are 26 core validation rules. You can see here. These 26 rules almost covers all the validation. … Continue reading

26. October 2011 by Zakir Hyder
Categories: CakePHP, Web Development | Tags: , , , , | Comments

Should I Use Database For Storing sessions in CakePHP?

Session handling is a important part of any web app. CakePHP offers 4 storage facilities for session storage. I will go through all of them and discuss advantages and disadvantages of 3 of them. They are cake (Saves the session … Continue reading

24. August 2011 by Zakir Hyder
Categories: CakePHP, PHP, Web Development | Tags: , , , | Comments

Prevent Your CakePHP App From XSS Attacks

This does not work in CakePHP 3 By default Cakephp will protect app against SQL Injection if you use CakePHP’s ORM methods (such as find() and save()) and proper array notation (ie. array(‘field’ => $value)) instead of raw SQL. But … Continue reading

11. August 2011 by Zakir Hyder
Categories: CakePHP, Web Development | Tags: , , , , , , | Comments

CakePHP and facebook SDK as Vendor

For most of the application on Facebook is simple but sometimes you have such a big application to develop you need to use a php framework. As I am a CakePHP developer, I like to use CakePHP for these type … Continue reading

28. July 2011 by Zakir Hyder
Categories: CakePHP, Facebook, Graph Api, PHP, Web Development | Tags: , , , | Comments

Disable Browser Cache in Cakephp

When developing web apps, sometimes it is better to disable browser cache. We can do it in php by following code So how do we set these in cakephp? Very simple This will produce headers like this I recommend calling … Continue reading

22. July 2011 by Zakir Hyder
Categories: CakePHP, PHP, Web Development | Tags: , , , , , , | Comments

Adding Google’s Data APIs to CakePHP – include_path Problem Fix

I recently developed a web app with youtube api. In this app I submit comment on any video, like or favorite any video. I used the zend gdata library. So i put them in the vendor folder and add it … Continue reading

10. June 2011 by Zakir Hyder
Categories: CakePHP, Google's Data API, PHP, Web Development | Tags: , , , | Comments

json_encode() json_decode() working with UTF-8

Working with different locale is very important now a days. But to work with different languages you face some problems – like all of a sudden some function will not work like it supposed to. For instance json_decode/json_encode. The problem … Continue reading

21. May 2011 by Zakir Hyder
Categories: PHP, Web Development | Tags: , , , | Comments

← Older posts

Newer posts →