jquery: how to check if a page is performing an ajax request?

ajax, jquery

Solution

Yes, this is totally possible. Start with the global ajax handlers here http://api.jquery.com/category/ajax/global-ajax-event-handlers/ .ajaxStart() and .ajaxStop() events are the most likely candidate to show your status indicator.

Problem

I want to build a function that fires with every ajax request. Like showing "loading...". I am using Jquery is that possible?

Original source

Related problems