Forums › Forums › Search & Filter Pro › Conflict with jquery.min.js
Tagged: conflict, jquery.min.js
- This topic has 6 replies, 2 voices, and was last updated 9 years, 6 months ago by
Ross.
-
Ross Moderator(Private) February 12, 2016 at 12:04 pm #36843
Hi there
Why are you adding a jquery.min.js to your site? WordPress comes with this automatically.
Thanks
Ross Moderator(Private) February 15, 2016 at 10:15 pm #37031Hey there
If I take a look now the search is working?
On any website, loading a second copy of jQuery is an issue, and is totally bad practice.
WordPress automatically loads its own copy (which you can find) on line 83 on your site:
<script type='text/javascript' src='http://www.example.com/wp-includes/js/jquery/jquery.js?ver=1.11.3'></script>
I don’t know what the issue is with teh other other jQuery, but like I say, this is prone to issues on WP unless you know what you are doing.
WP has tons of javascript, that is loaded using dependencies – https://developer.wordpress.org/reference/functions/wp_enqueue_script/ – plugins use these dependencies to load at the correct point in the code.
I’m assuming the way you are trying to do things does not preserve the dependencies in WP.
Thanks
-
AuthorPosts