• Resolved emchar1

    (@emchar1)


    Using WPForms Lite with reCaptcha v3 was working until recently. Researching the issue seems to pinpoint to an optimization plugin preventing the reCaptcha script from loading or executing correctly, however I disabled plugins systematically (LiteSpeed Cache), but the error persists. Followed these guides https://wpforms.com/docs/how-to-add-wpforms-to-an-elementor-page/ and https://wpforms.com/docs/resolving-the-attempt-to-submit-corrupted-post-data-error-in-wpforms/ ensured API Keys are correct, but no luck. Below is the error in the console log. TIA.

    Uncaught TypeError: grecaptcha.execute is not a function
    at wpformsRecaptchaV3Execute (puzl-boy/:461:17)
    at Object.submitHandler (wpforms.min.js?ver=1.9.8.2:5:9060)
    at d (jquery.validate.min.js?ver=1.21.0:4:1008)
    at HTMLFormElement.<anonymous> (jquery.validate.min.js?ver=1.21.0:4:1194)
    at HTMLFormElement.dispatch (jquery-min.js?ver=3.7.1:2:40035)
    at HTMLFormElement.<anonymous> (jquery-min.js ver=3.7.1:2:38006)
    wpformsRecaptchaV3Execute @ puzl-boy/:461
    submitHandler @ wpforms.min.js?ver=1.9.8.2:5
    d @ jquery.validate.min.is?ver=1.21.0:4
    (anonymous) @ jquery.validate.min.js?ver=1.21.0:4
    dispatch @ jquery.min.js?ver=3.7.1:2
    (anonymous) @ jquery.min.js?ver=3.7.1:2

    The page I need help with: [log in to see the link]

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Support Amjad Ali

    (@amjadali688)

    Hi @emchar1 ,

    Thanks for reaching out!

    Looking at the page, I see that you have Google reCAPTCHA v3 in the form. However, the Google reCAPTCHA badge is not appearing in the bottom right corner

    Please note that displaying the reCAPTCHA badge is required by Google. You can see this requirement here: https://developers.google.com/recaptcha/docs/faq#id-like-to-hide-the-recaptcha-badge.-what-is-allowed.

    You should display the badge, and after doing so, your form should submit without the “Attempt to Submit Corrupted Post Data” error.

    Accessing the form in an incognito window, I see that you’re using a Cookiebot Consent solution. We’ve noticed that some cookie consent solutions remove the resources required to properly load Google reCAPTCHA and its badge if the user clicks “Deny” or only allows essential cookies.

    If you don’t know why the badge isn’t loading, it might be a conflict with the cookie consent plugin. I recommend deactivating it and checking if the issue continues.

    Alternatively, you could replace Google reCAPTCHA with another CAPTCHA solution, such as hCaptcha or Cloudflare Turnstile. This should solve the issue.

    I hope this helps!

    Thread Starter emchar1

    (@emchar1)

    Hi Ali,

    Thanks tremendously! That pinpointed the issue. If I check Deny on the cookies consent, I don’t get the recaptcha badge, and I get the error. But if I allow cookies, then I do get the badge and the form submits fine – no error. Is this by design? Is there something in my cookies configuration I need to change so that if someone denies cookies, the badge will still show up and they will be able to submit the form? Or is this beyond the scope of WPForms?

    Thanks again!

    Plugin Support Amjad Ali

    (@amjadali688)

    Hi @emchar1 ,

    You’re welcome, happy to help!

    Yes, this issue is related to the Cookiebot Consent Solution, and unfortunately it’s something we cannot fix from the WPForms side.

    You can reach out to Cookiebot’s team here: https://termly.io/products/cookie-consent-manager/ to report the issue that is causing Google reCAPTCHA to not display when cookies are denied.

    Alternatively, you could use hCaptcha or Cloudflare Turnstile as a replacement for reCAPTCHA to prevent this error from occurring.

    Hope this helps clarify things!

    Thread Starter emchar1

    (@emchar1)

    Thanks again! I will reach out to Termly’s side and take it from there. Closing the ticket now.

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘Attempt to submit corrupted post data.’ is closed to new replies.