8. Using the Full Power of Ajax
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( )
.
About $.ajax( )
You call $.ajax( )
with a pair of name and value options. jQuery provides 20 such options. ...
Get jQuery: Visual QuickStart Guide now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.