Tutorials References Exercises Sign Up Menu
Create Website Get Certified Pro

jQuery ajaxStart() Method

❮ jQuery AJAX Methods


Show a "loading" indicator image when an AJAX request starts:

  $(this).html("<img src='demo_wait.gif'>");
Try it Yourself »

Definition and Usage

The ajaxStart() method specifies a function to be run when an AJAX request starts.

Note: As of jQuery version 1.8, this method should only be attached to document.



Parameter Description
function() Required. Specifies the function to run when the AJAX request starts

❮ jQuery AJAX Methods