This article has useful links for a CakePhp new comer to get started with using Ajax. As the manual mentions, using Ajax in your Cake application is very easy. Ajax is implemented in Cake through the Cake Ajax Helper, which is included with Cake by default. The Cake Ajax helper utilizes the ever-popular Prototype and script.aculo.us libraries for Ajax operations and client side effects.
Below are some useful resources that got me started with Ajax in CakePHP. I hope these will help you too:
1. Getting Started:
- http://grahambird.co.uk/cake/tutorials/ajax.php
This is probably the best place to start. Graham Bird wrote an excellent tutorial for getting started with CakePhp and Ajax: - http://manual.cakephp.org/chapter/helpers
Once you are done understanding Graham Bird’s tutorial, you should be ready to understand what the manual says about the Ajax Helper. You will find Ajax Helper way below in this page. - http://infor96.com/cake/posts/
This is another excellent Ajax example with CakePhp. It shows a demo Ajax blog. You can also download the source. - http://cakebaker.42dh.com/2006/01/18/submit-a-form-with-ajax/
CakeBaker’s blog on Submitting A Form With Ajax is a small but resourceful blog to read, especially the comments. - http://www.nolimit-studio.com/baking/2006/05/16/adding-visual-effects-to-ajax-calls/
Baking with Sosa has an interesting blog on Adding Visual Effects to Ajax Calls.
2. AutoComplete:
- http://manual.cakephp.org/chapter/helpers
The Manual has a good example to get you started with Ajax Autocomplete. - http://cakebaker.42dh.com/2006/06/06/autocompletion-the-easy-way/
This blog by Cakebaker discusses a component made by Nate for easy implementation of autocomplete. - http://bakery.cakephp.org/articles/view/77
The bakery has a good example for the same component.
3. Ajax Redirect:
- http://bakery.cakephp.org/articles/view/92
- http://cakebaker.42dh.com/2006/03/15/redirect-with-ajax/
- http://cakebaker.42dh.com/2006/03/28/a-simple-redirect-component/
4. Ajax Validation:
5. Encoding:
6. Ajax Uploader:
7. Ajax Star Rating:
8. Ajax Chat:
9. TinyMCE with Ajax:
10. Dojo Helper
11. Updating Select Box using Ajax
- http://www.devmoz.com/blog/2007/04/04/cakephp-update-a-select-box-using-ajax/
This tutorial shows how to update a select box using ajax call. Very useful
12. CakePhp API
- http://api.cakephp.org/class_ajax_helper.html
Once you are confortable with using Ajax with Cake, the only place you need to look for any reference is the API.
13. Search The Cake PHP Google Group
- http://groups.google.com/group/cake-php/search?group=cake-php&q=ajax&qt_g=Search+this+group
Yes. You will be surprized to find out the amount of information you will get to know from searching the group. To search the group for “ajax”, use the link above.
Feel free to leave comment. And, if you think I have left out some useful links, do let me know too.
Không có nhận xét nào:
Đăng nhận xét