Support » Fixing WordPress » jQuery conflicts newbie

  • Resolved Slangebein

    (@slangebein)


    I’m using slider posts with the theme I have, and as you’ll see from the header info at http://dehydrogenated.net, it loads an old version of jQuery, 1.3.2.

    I’ve tried putting newer versions in the theme library and linking to them but it won’t work. I need jQuery to load right so I can use certain plugins while still having the slider functionality from this theme. That, and I also want complete cohesion on my page(s) with jQuery, of course.

    I have looked at possible solutions like this: http://digwp.com/2009/06/including-jquery-in-wordpress-the-right-way/

    …but I’m pretty new to all this, and don’t know enough about what’s being said there to know if it will mess something up.

    Thanks for any help you can give!

Viewing 3 replies - 1 through 3 (of 3 total)
  • You can try adding this to functions.php. I think the deregister script will stop other jquery, then you can just call from google on the next line, or use the one thats included with WordPress. Not sure if it will help or not but its worth a try. I would think that using a new version of jQuery won’t hurt your slider thats currently using the older version.

    wp_deregister_script('jquery');
    wp_register_script('jquery', ("http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"), false, '1.4.2', false);
    wp_enqueue_script('jquery');

    Ah ha, that did the trick! Thanks a lot!

    Awesome. Glad it worked.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘jQuery conflicts newbie’ is closed to new replies.