I am using such construction:
$('#wait').ajaxStart(function() { if ($(this).not(':visible')) $(this).showWarning(); }).ajaxComplete(function() { if ($(this).is(':visible')) $(this).hideWarning(); }).ajaxError(function() { alert('Unexpected error...'); }); And I want to disable submit button every time the user clicks on it. In order to make it universal - I want to do it in ajaxStart method, so is there any way to get the button's id which initialized the request? Thank you