Advertisement
blondeweb

Untitled

Dec 31st, 2014
490
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. $(document).ready(function(){
  2.    
  3.   // Follow
  4.    
  5.   $('.follow').click(function(){
  6.     $('.l').html("Seguindo");
  7.     var id_of = $('.idFollow').val();
  8.     var id_to = $('.add').attr("attr-c");
  9.    
  10.     var follow = $.ajax({
  11.       url:"/perguntando.com/auth/ajax/processo.php",
  12.       type:"POST",
  13.       data:{ action:"follow", id_of: id_of, id_to: id_to },
  14.     });
  15.    
  16.     follow.done(function(e){
  17.       $('.invite').html(e);
  18.     });
  19.  
  20.   });
  21.  
  22.   // Unfollow
  23.  
  24.   $('.unfollow').click(function(){
  25.     $('.l').html("Seguir");
  26.     var id_of = $('.idFollow').val();
  27.     var id_to = $('.add').attr("attr-c");
  28.    
  29.     var unFollow = $.ajax({
  30.       url:"/perguntando.com/auth/ajax/processo.php",
  31.       type:"POST",
  32.       data:{ action:"unfollow", id_of: id_of, id_to: id_to },
  33.     });
  34.    
  35.     unFollow.done(function(e){
  36.       $('.invite').html(e);
  37.     });
  38.  
  39.   });
  40. });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement