Hi,
Thanks for sharing the link of the page where you have jQuery errors. By looking at the browser’s JavaScript console as well as at the source code of that page, we noticed that you are probably using some sort of “minifier” or “compressor” for JS assets, and the actual jQuery 3.6.0 official library is only loaded at the end of the page, in the “footer” of your HTML source code.
The code flagged as invalid is inside a “ready” statement, but it seems that this is not firing properly in your case.
Our suggestion is to load the JS assets in the existing and regular HEAD section of your Theme, because the “footer” is not a real tag, it’s a lazy-loading technique that sometimes it can cause issues when you minify, compress or cache JS assets.
Unfortunately, this is not something you can fix in Vik Booking, it has to be fixed in your Theme or by properly configuring the plugin or the theme responsible of this invalid loading of the JS assets.
Right now it’s failing a simple jQuery method (“.on”) inside a document-ready statement, which is not normal.
In case you cannot get this issue solved by working on your Theme settings or on some third party plugins responsible of the compression of the JS assets, we invite you to reach out to our technical team through our website so that we can assist you better. Thank you.
The VikWP Team
Thank you, I’ll take a look and shout if i need more assistance.
No problem! We suggest investigating more on who is loading the JavaScript declarations and scripts, because that’s who’s responsible of the issue. It’s probably the Theme and its current settings.
Right now you have inline script declarations in the HEAD of your HTML document, while the JavaScript assets are being lazy-loaded in the “footer” of the page. This is wrong, because if a Theme wants to adopt lazy-loading techniques, all JavaScript references should be in the “footer” of the page, not some in the “head”, and the actual core libraries in the “footer”.
If you can find a setting in your Theme to prevent this lazy-loading technique, at least for jQuery, the error will be gone.