SHARE
TWEET

Untitled

a guest Feb 23rd, 2019 59 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. $("header")
  2.     .on({
  3.         ajaxStart: function () {
  4.             $(this).addClass("ajax-loading");
  5.         },
  6.         ajaxStop: function () {
  7.             $(this).removeClass("ajax-loading");
  8.         }
  9.     });
  10.    
  11. $("header")
  12.     .on({
  13.         ajaxStart: function () {
  14.             $(this).css( 'cursor', 'progress' );
  15.         },
  16.         ajaxStop: function () {
  17.             $(this).css( 'cursor', 'default' );
  18.         }
  19.     });
  20.    
  21. $("header")
  22.     .on({
  23.         ajaxStart: function () {
  24.             $('body').css( 'cursor', 'progress' );
  25.         },
  26.         ajaxStop: function () {
  27.             $('body').css( 'cursor', 'default' );
  28.         }
  29.     });
  30.    
  31. $.ajax({
  32.   beforeSend: function() { //function to do whatever you want to do; }
  33. });
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Not a member of Pastebin yet?
Sign Up, it unlocks many cool features!
 
Top