Support » Plugin: Meteor Slides » I only want to use Meteor Slides in some page headers and not others.

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Josh Leuze

    (@jleuze)

    You can do this with a PHP conditional, here’s an example that would load the slideshow on the frontpage and the about page:

    <?php if ( is_front_page() ) {
    	if ( function_exists( 'meteor_slideshow' ) ) { meteor_slideshow( "home","" ); }
    } elseif ( is_page( 'about' ) ) {
    	if ( function_exists( 'meteor_slideshow' ) ) { meteor_slideshow( "about","" ); }
    } ?>

    can you explain this further? Where do I put this .php in the header.php? I followed the instructions for the meteor slideshow.

    I added the following in header.php:

    <div class=”slide-wrapper”>
    <?php if ( function_exists( ‘meteor_slideshow’ ) ) { meteor_slideshow(); } ?>
    </div>
    <div class=”logo”>

    I added the following to styles.css:
    div.slide-wrapper
    { position: absolute;
    display: block;
    top: 102px;
    left: 66px;
    height: 250px;
    width: 1050px;
    }

    The code works great but I only want it to show up in my header on some pages. If I add the .php that you wrote do I leave the code in the header.php and add yours to it? Will I need additional code in my styles.css?

    Thanks!

    Plugin Author Josh Leuze

    (@jleuze)

    Just replace the standard template tag with the conditional one:

    <?php if ( function_exists( 'meteor_slideshow' ) ) { meteor_slideshow(); } ?>
Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘I only want to use Meteor Slides in some page headers and not others.’ is closed to new replies.