Advertisement
bowenac

ajax

May 28th, 2014
241
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1.       jQuery('#export').click(function() {
  2.         jQuery( ".attrLoading" ).slideDown(500);
  3.           $.ajax({
  4.           url: '../wp-content/plugins/posts-image-fix/ajax.php',
  5.           context: document.body
  6.           }).done(function(res) {
  7.           jQuery(".status").append(res);
  8.           jQuery( ".attrLoading" ).slideUp(500);
  9.           });
  10.           //Get status live updates
  11.           function getStatus(){
  12.             $.ajax({
  13.             url: '../wp-content/plugins/posts-image-fix/ajax-status.php',
  14.             context: document.body
  15.             }).done(function(res) {
  16.             jQuery(".status").append(res);
  17.             if (res) {
  18.  
  19.             };
  20.             });
  21.  
  22.           })
  23.           getStatus(); //start it up the first time
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement