Q: JS - AjaxSucess Targeting Specific AJAX Call I have several AJAX calls happening on my page simultaneously, and I want to be able to track when a specific AJAX call is complete. I am unable to modify any existing code (including those that does the AJAX call), but I am able to add additional JS.
I have been looking into $.ajaxSuccess() which detects when any AJAX calls have been successfully completed. The problem is that this function will detect when all AJAX calls complete instead of a specific one. How would I get $.ajaxSuccess() to target one specific AJAX call?
$('div.foo').ajaxSuccess( function() { ... });

A: First, global ajax handlers should always be attached to the document (unless you're using an old version of jquery and don't plan to ever update.)
Secondly, the third parameter of the callback is the options passed to the ajax request, therefore you can use it to detect what the url was and act accordingly.
$(document).ajaxSuccess(function(event,jqXHR,options) {
    console.log(options.url);
});

