jQuery is not defined

Hi I was wondering if anyone could help with the following JS errors I’m getting in the Chrome console and how I may fix these on https://magicwedding.co.uk/

I’ve also added a list of 404 errors realted to Javascript files on my X site. Thanks in advance!

Uncaught ReferenceError: jQuery is not defined
    at (index):222
jquery-migrate.min.js:2 JQMIGRATE: Migrate is installed, version 1.4.1
x.js:1 Uncaught TypeError: Cannot read property 'action' of undefined
    at e.default (x.js:1)
    at HTMLDocument.<anonymous> (x.js:1)
    at i (jquery.min.js:2)
    at Object.fireWith [as resolveWith] (jquery.min.js:2)
    at ready (jquery.min.js:2)

Hi there,

I see many of your script tags have a defer="defer" attribute on theme. This seems to be allowing scripts to load out of order which is causing the error. Are you using any kind of performance plugin to add these attributes?

Thanks Alexander, I did have a plugin that deferred the JS so I’ve just disabled that and the “JQuery is not defined” error has gone so thanks for that. I still have the other JS errors, any idea how I could resolve those? Thanks

Hi @kevgregson,

I still see the same error (jQuery is not defined), and it’s probably due to custom added jQuery library hosted in google.

<script type='text/javascript' src='//ajax.googleapis.com/ajax/libs/jquery/1.12.4/jquery.min.js'>

Could you try removing it and let Wordpress use the default one? Then please clear the cache and check it again.

Thanks!

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.