function processJQueryAjaxError(event, jqXHR, ajaxSettings, thrownError) {
var message = 'AJAX Error: ' +
(jqXHR.statusText || 'unknown') +' '+
(ajaxSettings.type || 'unknown');
atatus.notify(thrownError || event.type, {
status: jqXHR.status,
statusText: jqXHR.statusText,
type: ajaxSettings.type,
url: ajaxSettings.url,
ajaxErrorMessage: message,
contentType: ajaxSettings.contentType,
activeTarget: event.target && event.target.activeElement ? event.target.activeElement.outerHTML : undefined
});
}
$(document).ajaxError(processJQueryAjaxError);
FAQ
How to notify jQuery Ajax errors?
Notify jQuery Ajax errors to Atatus with straightforward code integration. Sign up with Atatus for comprehensive error tracking and resolution solutions.
You can add following code to notify jQuery Ajax errors to Atatus.