Advertisement
Guest User

Untitled

a guest
Feb 25th, 2020
113
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.15 KB | None | 0 0
  1. $("span#unlike_Post").click(function(e){
  2. e.preventDefault();
  3.  
  4. const btnEval = $(this).data('id');
  5. const postID = btnEval;
  6. const likedUser = $("#likedUser").val();
  7. const userUID = $("#postUserUID").val();
  8. const uid = $(this).data("uid");
  9.  
  10. $.ajax(
  11. {
  12. url: '/resources/jquery/addons/ajax/site/forum/post.unlike.php',
  13. method: 'POST',
  14. data: {
  15. sent: 1,
  16. postID: postID,
  17. likedUser: likedUser,
  18. userUID: userUID,
  19. uid: uid
  20. },
  21. success: function(response) {
  22. $('li.' + postID).prepend(response);
  23. $('.nk-forum-topic-author-likes').text(".nk-forum-topic-author-likes");
  24. },
  25. dataType: 'text'
  26. }
  27. )
  28. });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement