Guest User

Untitled

a guest
Sep 19th, 2018
76
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.62 KB | None | 0 0
  1. /* form submit */
  2. $(".js-form-submit").submit(function() {
  3. var th = $(this);
  4. $.ajax({
  5. type: "POST",
  6. url: "mail/mail.php",
  7. data: th.serialize()
  8. }).done(function() {
  9. var successCallback = th.closest('.form_wrapper').find('.success_callback');
  10. successCallback.fadeIn(0).css({'transform':'scale(1)'});
  11. setTimeout(function() {
  12. th.trigger("reset");
  13. successCallback.fadeOut().css({'transform':'scale(0)'});
  14. $.magnificPopup.close();
  15. }, 1900);
  16. });
  17. return false;
  18. });
Add Comment
Please, Sign In to add comment