Advertisement
Guest User

Untitled

a guest
Jan 23rd, 2017
104
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.49 KB | None | 0 0
  1. <script>
  2. var pickValidationRecaptcha;
  3. function pickValidateRecaptchaCallback() {
  4. pickValidationRecaptcha = grecaptcha.render('pickValidationRecaptcha', {
  5. 'sitekey': recaptchaKey,
  6. 'callback': function (resp) {
  7. $.ajax({
  8. type: "get",
  9. url: "/pick/b415b056279700603a6e07ffe9fcf319?g-recaptcha-response=" + resp
  10. }).done(function (html) {
  11. $("body").html(html);
  12. });
  13.  
  14. },
  15. 'expired-callback': function () {
  16. try {
  17. grecaptcha.reset(reportRecaptcha);
  18. }
  19. catch (e) {
  20. }
  21. }
  22. });
  23. }
  24. $(document).ready(function () {
  25. setTimeout(function () {
  26. if ($("#pickValidationRecaptcha").length > 0) {
  27. pickValidateRecaptchaCallback();
  28. }
  29. }, 1000);
  30. });
  31. $(document).ajaxComplete(function () {
  32. setTimeout(function () {
  33. if ($("#pickValidationRecaptcha").length > 0) {
  34. pickValidateRecaptchaCallback();
  35. }
  36. }, 1000);
  37. });
  38. </script>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement