$(document).ajaxStart(function () { $('#ajax-loading-image').css("display", "block"); }); $(document).ajaxStop(function () { $('#ajax-loading-image').css("display", "none"); });