• LearnEd Studio

    (@lesdeveloper)


    Hi Team,

    We have starting facing an issue with our CF7 form submissions when the integration with recaptcha V3 keys is active.

    If we remove the keys, the form works fine.

    Here are the browser console errors that we get when the form submissions are blocked:

    TypeError: Cannot set properties of null (setting ‘innerText’)
    at d (index.js?ver=5.8.5:1:7357)
    at index.js?ver=5.8.5:1:7105
    at index.js?ver=5.8.5:1:1127
    at index.js?ver=5.8.5:1:8157
    at index.js?ver=5.8.5:1:1127
    at n (index.js?ver=5.8.5:1:1941)
    at l (index.js?ver=5.8.5:1:6212)
    at index.js?ver=5.8.5:1:429
    (anonymous) @ index.js?ver=5.8.5:1
    Promise.then (async)
    catch @ recaptcha__en.js:385
    o @ index.js?ver=5.8.5:1
    wpcf7.submit @ index.js?ver=5.8.5:1
    (anonymous) @ index.js?ver=5.8.5:1

    If I click on the error causing js link, the error is in the highlighted line of code in the following block:

    document.addEventListener("DOMContentLoaded", (e=>{
    var t;
    wpcf7_recaptcha = {
    …null !== (t = wpcf7_recaptcha) && void 0 !== t ? t : {}
    };
    const c = wpcf7_recaptcha.sitekey
    , {homepage: n, contactform: a} = wpcf7_recaptcha.actions
    , o = e=>{
    const {action: t, func: n, params: a} = e;
    grecaptcha.execute(c, {
    action: t
    }).then((e=>{
    const c = new CustomEvent("wpcf7grecaptchaexecuted",{
    detail: {
    action: t,
    token: e
    }
    });
    document.dispatchEvent(c)
    }
    )).then((()=>{
    "function" == typeof n && n(…a)
    }
    )).catch((e=>console.error(e)))
    }
    ;

    As soon as we remove the captcha keys, form submissions work fine but spammers have a field day with our contact form.

    Please help solve this.

    FYI – we have the latest version of Contact Form 7 (5.8.5) installed and are also on the latest WordPress version (6.4.2).

    Also, we have removed captcha for now since our client needs at least valid submissions to go through; they are bearing with spam, for the moment.

    Thanks!

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

Viewing 5 replies - 1 through 5 (of 5 total)
  • Plugin Author Takayuki Miyoshi

    (@takayukister)

    What other plugins and theme do you use on the site?

    Thread Starter LearnEd Studio

    (@lesdeveloper)

    We are using the Owly theme (with a child theme activated). Attaching a screenshot of the plugins on the site so that you get an idea which are active or not, need updates etc.

    Plugin Author Takayuki Miyoshi

    (@takayukister)

    Try switching to the default theme, deactivating all plugins excluding Contact Form 7, WooCommerce and WordPress Importer, and clearing all cache data.

    Why you are advised to deactivate plugins and switch to the default theme.

    Thread Starter LearnEd Studio

    (@lesdeveloper)

    Since we don’t have a corresponding development instance of this website, it will have to be done on the live site, which will disrupt the site for the visitors.

    We need to plan out a good time for this, when visitors are typically low as per Analytics.

    Our support staff handling this thread will be on leave for the New Years, in fact till 8th of Jan.

    Request you to please keep this ticket open despite no active responses from us; we shall check this once work resumes.

    Thanks!

    Hello together

    We have exactly the same issue on our site. so i checked the plugins which we have in use together. We also use WPBakery Page Builder (and of course contact form 7 with recaptcha integration), so i deactived this one for a test. (WPBakery) Then the problem will no longer occur.
    Sadly not a workarround or a fix, because this one is used to build the whole page.

    May you can keep me updated and hope this one will help you!

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘reCaptcha V3 Integration Causing Form Submission Errors’ is closed to new replies.