Meteor Slides
[resolved] Conflict with WP-Bootstrap Theme? (8 posts)

  1. arrjaytea@gmail.com
    Posted 3 years ago #

    Link to a beta redesign I'm working on using the Bootstrap Framework, and I can't for the life of me get meteor slider and it to play nice.


    Meteor Slider works only if I use "restore jquery" - which unfortunately seems to break my menu.

    Any ideas?


  2. Josh Leuze
    Plugin Author

    Posted 3 years ago #

    Hi, the theme is deregistering the default copy of jQuery that is built into WordPress and registering it's own copy in the functions.php:

    wp_deregister_script('jquery'); // initiate the function
      wp_register_script('jquery', get_template_directory_uri().'/library/js/libs/jquery-1.7.1.min.js', false, '1.7.1');

    For some reason jQuery is also being deregistered in library/bones.php:

    if (!is_admin()) {
    		wp_deregister_script('jquery');                                   // De-Register jQuery
    		wp_register_script('jquery', '', '', '', true);                   // It's already in the Header

    Remove both of those code snippets and it will use the default copy of jQuery in WP. WordPress loads jQuery in no conflict mode.

    That means you can't use the "$" shortcut, you have to use the full "jQuery" version. So the library/js/scripts.js file won't work. Wrap the code in that file with this and it will work fine:

    jQuery(document).ready(function($) {
        // scripts.js code

    Now the Meteor Slides slideshow script and and the theme's scripts should both be working.

    Maybe for future use try a different Bootstrap theme.

  3. arrjaytea@gmail.com
    Posted 3 years ago #

    Cheers. Seems to have worked like a charm on first glance.

  4. Josh Leuze
    Plugin Author

    Posted 3 years ago #

    Glad to hear it!

  5. Erik Kroon
    Posted 2 years ago #

    I've viewed a few cases/posts and this one describes my problem best.
    Trying the solutions the errors in my dev tools (chrome) are actually getting more and more.
    I set all files back to their original $ etc.

    Is there any chance that a newer solution is available?
    I'm using v 1.5.1 meteor slides and WordPress 3.6.1
    In my theme i use the bones/bootstrap theme scripts


    the slider has 3 images in it and it is there but not really showing the images

    Hope to hear from anyone, as this post is already 11 months old.

  6. Erik Kroon
    Posted 2 years ago #

    I found a solution which is a little different to the above one
    Only changed this in scripts.js in the bones library/js folder
    $(document).ready(function() {
    jQuery(document).ready(function($) {

    Then an error in the meta section of metoer plug-in was still there

    I changed this in my template files
    <?php if ( function_exists( 'meteor_slideshow' ) ) { meteor_slideshow( "algemeen", "metadata" ); } ?>
    <?php if ( function_exists( 'meteor_slideshow' ) ) { meteor_slideshow( "algemeen" ); } ?>

    Et voila, maybe not a programmers choice but then again it works fine now

  7. Josh Leuze
    Plugin Author

    Posted 2 years ago #

    @punchcreative The second parameter should still be in the template tag, but if you don't have any metadata, just leave it blank:

    <?php if ( function_exists( 'meteor_slideshow' ) ) { meteor_slideshow( "algemeen", "" ); } ?>
  8. Erik Kroon
    Posted 2 years ago #

    Thanks Josh

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic