• Resolved Carl Gross

    (@carlgross)


    Hello. I have the plugin enabled on my site, and on every page–including my home page–it is displaying the ‘protected by reCAPTCHA’ logo. I now have an error in the JavaScript console on my homepage:

    Uncaught SyntaxError: missing ) after argument list

    sreenshot.

    This seems to be related to the CF7 plugin. I say that because when I deactivate the plugin, the error is not displayed. When I reactivate the plugin, the error returns. How can I resolve this?

    I’ve seen other posts with people having a similar issue (example). But it seems like in all those cases, the issue was due to a particular plugin/theme, and fixed only after an update by said plugin/theme.

    I am using version v5.4 of the plugin.

    Thanks in advance.

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

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

    (@takayukister)

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

    Marcelo F.

    (@waltoslaguna)

    Same problem, it works badly with google recaptcha. The contact form does not work.

    Error:
    https://prnt.sc/107nwcn
    https://prnt.sc/107nxap

    Thread Starter Carl Gross

    (@carlgross)

    @takayukister

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

    I can tell you that I’ve tested the issue with all my plugins deactivated, and the issue is not present. As soon as I activate CF7, the issue arises. To answer your question, the plugins installed on my site are:

    Akismet Anti-Spam
    BackWPup
    Breadcrumb NavXT
    Classic Editor
    Contact Form 7
    Elementor
    Flamingo
    HTML Editor Syntax Highlighter
    Jetpack by WordPress.com
    Master Slider
    Media Library Assistant
    Outdated Plugin Notifier
    SVG Support
    TablePress
    Ultimate Post List
    Widget Options
    Hummingbird
    Magic Liquidizer Responsive Table
    Wordfence Security
    WP Rollback
    Yoast Duplicate Post
    Yoast SEO

    Theme is Spacious (free version). I have not tested the issue with the WordPress default theme.

    Plugin Author Takayuki Miyoshi

    (@takayukister)

    Try switching to the default theme and deactivating all plugins excluding Contact Form 7, Akismet Anti-Spam, Classic Editor, Flamingo, and Yoast SEO.

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

    Thread Starter Carl Gross

    (@carlgross)

    OK I just switched to the default theme (Twenty Twenty), and had only CF7 activated. The issue went away. So I guess my theme is the culprit? If so, what do I do now? Specifically, if I bring this up with theme support, I’m sure you know that they will point to the CF7 plugin and say, “The bug is in that plugin.” If they say that, what would be my best reply? Maybe I don’t mention your plugin just yet, and tell them only, “The issue occurs when I activate your theme.”

    • This reply was modified 4 years ago by Carl Gross.
    Plugin Author Takayuki Miyoshi

    (@takayukister)

    I’m not sure if the real culprit is the theme. I thought the prime suspect would be Hummingbird because the direct cause of this problem is an invalid insertion of HTML fragment defer onload='", and Hummingbird seems to have a feature to do it. I would advise you to focus on the plugin before reporting to the theme author.

    Thread Starter Carl Gross

    (@carlgross)

    >> I would advise you to focus on the plugin before reporting to the theme author.

    By ‘plugin’ you mean CF7, correct?

    Plugin Author Takayuki Miyoshi

    (@takayukister)

    Hummingbird.

    Thread Starter Carl Gross

    (@carlgross)

    Haven’t we already ruled that out as a culprit?

    Plugin Author Takayuki Miyoshi

    (@takayukister)

    Have you tested with only Hummingbird deactivated (and clearing cache) and the current theme activated?

    Thread Starter Carl Gross

    (@carlgross)

    Sorry for the delay. I just tested the site, with all plugins deactivated, except for Hummingbird. The issue is not present.

    I also tested the site in which all plugins were activated, except Hummingbird. The issue is still present.

    During the tests, my usual theme (Spacious) was active, and I was sure to carry out hard refreshes.

    Thoughts?

    Plugin Author Takayuki Miyoshi

    (@takayukister)

    I downloaded the Spacious theme package and searched through the files by “defer”, but found nothing. I don’t think the theme has something to do with this issue.

    Thread Starter Carl Gross

    (@carlgross)

    Update: I found the cause of the issue. It was due to custom code that *I* had added in my child theme–code to defer the loading of scripts. Geesh.

    So sorry about that–I very much appreciate your time. Let’s consider this resolved.

Viewing 13 replies - 1 through 13 (of 13 total)
  • The topic ‘Plugin causing console error: SyntaxError: missing ) after argument list’ is closed to new replies.