June 2009
Intermediate to advanced
240 pages
5h 19m
English
In the previous chapter, you saw a number of the Ajax functions available in jQuery: load( ), $.get( ), and so on. Those functions are good as quick Ajax solutions, but they’re not complete solutions. What if you want to set a timeout period for your Ajax request? What if you want to take control of the XMLHttpRequest object creation process? What if you want to handle any errors returned by an operation?
For these tasks and more, jQuery provides the full-fledged $.ajax( ) function. This function gives you access to the full power of Ajax, while still staying in jQuery. This chapter is all about $.ajax( ).
You call $.ajax( ) with a pair of name and value options. jQuery provides 20 such options. ...