• Resolved MeOnline

    (@webber2012)


    After upgrading WordPress to 4.5, suddenly GravityForms stopped working (forms didn’t show anymore in the frontend).

    The following error was on the page:
    jquery.js?ver=1.12.3:2 Uncaught Error: Syntax error, unrecognized expression: ul.art-hmenu a[href=#]

    To fix this with a theme made via Artisteer, open wp-content/themes/yourtheme/script.js and do the following:
    —-
    The link location (hash marks, #, in this case) should be quoted: [href=”#”] and -not- without quotes around the # ([href=#])

    After changing that, don’t forget to purge browser cache!

    It seems that this is some kind of bug – also happening with some commercial themes it seems.

Viewing 7 replies - 1 through 7 (of 7 total)
  • Moderator James Huff

    (@macmanx)

    The problem is detailed here: https://www.ads-software.com/support/topic/read-this-first-wordpress-45-master-list?replies=7&view=all#post-8271654

    In short though, you’ll need to contact Artisteer about an update to your theme.

    Thanks to you both. This just happened to one of my sites too and with your instructions I could easily update old theme.

    Moderator James Huff

    (@macmanx)

    You’re welcome!

    Thread Starter MeOnline

    (@webber2012)

    Glad to hear you also managed to get the issue fixed ottomek.

    Unfortunately Aristeer is a theme creator so not a specific theme provider and they have dropped support for Aristeer since they introduced Themler, the follow up of Artisteer. :-/

    So this is basically a sort of Artisteer bug which apparently surfaces with the latest version of WordPress and in combination with certain plugins like GravityForms.

    All themes created with Artisteer could possibly have this bug/issue I suspect.

    Moderator James Huff

    (@macmanx)

    It’s possible, and unfortunately it’s up to them to fix.

    The short version of https://www.ads-software.com/support/topic/read-this-first-wordpress-45-master-list?replies=7&view=all#post-8271654 is that they (and a few other theme developers) were using jQuery incorrectly (against documented coding standards), and jQuery was eventually updated to close the exploit they were using. WordPress was updated to include the latest jQuery, and now the exploit they were using can no longer be exploited.

    It’s not something that can be fixed in WordPress, as WordPress is simply using the latest jQuery, it’s not a bug. It’s up to the theme developers to fix this in their own themes, or perhaps it’s time to switch to a better theme that respects coding standards. There are many great free themes these days: https://www.ads-software.com/themes/browse/popular/

    Thread Starter MeOnline

    (@webber2012)

    Thanks for explaining.
    I also found that several commercial theme providers had the same issue indeed.

    In the Artisteer case, the file that needed to be modified is one that by default is supplied and created with -every- Artisteer generated theme as far as I am aware.
    In the meanwhile I also pointed this out to Artisteer so we’ll have to wait and see if they’ll pick this up – I do have my doubts though.

    I forgot to mention where the specific code is in the file, so hereby a better version of the fix:

    Open wp-content/themes/yourtheme/script.js

    ————————————————–
    On or around line 22 find:
    jQuery(‘ul.art-hmenu a[href=#]’).click(function () { return false; });

    Change this to:
    jQuery(‘ul.art-hmenu a[href=”#”]’).click(function () { return false; });
    ————————————————–
    Note the quotes (“) that have been submitted before and after the hashtag sign (#) in the changed code.

    When this code is not available (not sure if this is possible) or you cannot find it, I would suggest to search for a[href=#] in the code of the files of your theme and change that to a[href=”#”]
    I believe it should be in one of the .js files of the theme.

    Moderator James Huff

    (@macmanx)

    Thanks for sharing your fix!

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Uncaught Error: Syntax error, unrecognized expression: ul’ is closed to new replies.