ism ism - 1 year ago 57
Ajax Question

how to get ajax duration from ajaxError

Is there a way to extract the duration that an ajax request took from the ajaxError call?

$(document).ajaxError(function (event, jqXHR, ajaxSettings, thrownError) {


Answer Source

I think using beforesend() and complete() is the easiest way to calculate it.

Getting AJAX Request Duration

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download