[Resolved] Slider / Features only to display on frontpage/blogroll

Home Forums Support [Resolved] Slider / Features only to display on frontpage/blogroll

Home Forums Support Slider / Features only to display on frontpage/blogroll

Viewing 7 posts - 1 through 7 (of 7 total)
  • Author
    Posts
  • #108655
    Tobias Hjorth

    Hi all

    I’ve found myself a nice featured slider which I can implement by using GPHooks (after header) – But I can’t figure out how only to display the slider on the FrontPage/blogroll and nowhere else. – I’m sure there’s some sneaky code I can use in GPHooks without implementing the slidercode into the theme /main php

    Tried to search for the answer in the forums but found no solution.

    #108669
    Tom
    Lead Developer
    Lead Developer

    You can wrap it in a PHP if conditional like so:

    <?php if ( is_front_page() ) : ?>
        This will only show up on the homepage
    <?php endif; ?>

    Then click Execute PHP and you should be good to go πŸ™‚

    #109079
    Tobias Hjorth

    Thanks Tom, that worked just like you said πŸ™‚

    #109137
    Tom
    Lead Developer
    Lead Developer

    Perfect πŸ™‚

    #266497
    takkularapsis

    Hi,

    I have the same problem. I want to use slider only in front page in GPhooks -> After Header.
    Slider shortcode is [huge_it_slider id=”3″]

    How to give help for a dummy like me? πŸ™‚

    I didnt get the earlier answer, so any help would be good.

    #266498
    takkularapsis

    Ok, i made it work…Thanks! πŸ˜€

    #266604
    Tom
    Lead Developer
    Lead Developer

    Glad you got it working πŸ™‚

Viewing 7 posts - 1 through 7 (of 7 total)
  • You must be logged in to reply to this topic.