How to check if there is an ajax running on your page?
How to check if there is an ajax running on your page? Here’s a code below that can help you figure it out.
1 2 3 4 5 6 7 | jQuery( document ).ready( function ($) { $(document).ajaxStart( function () { console.log( 'ajax true' ); }).ajaxStop( function () { console.log( 'ajax false' ); }); }); |