• Hi all,

    Got the following question:

    In my menu i will be having DEALS and STORES. Both will have submenus. What i basically want is that if a page is a subpage of DEALS it will show productslider A. If they go to a page which is a sub under STORES i want them to get productslider B in the header.

    So far i have this which works but is a pain in the *** because i need to manually add all the page ID’s. There will be lots and lots of them. I read there is a way to do it like i want but i dont understand how it works and what to put where.

    <div class="container">
        <?php if (is_page (array('1678','1714','1717','1721','1725','1730','1732','1734','1736','1738','1740','1742','1744','1746','1748','1750','1752','1754','1756','1758','1760','1762'))) {
        echo do_shortcode('[products_tabs per_page="-1" slider="yes" orderby="menu_order" order="desc" categories="must-have, best-seller, special-offers, " ]'); }
        elseif (is_page ('stores')) {
        echo do_shortcode('[products_tabs per_page="-1" slider="yes" orderby="menu_order" order="desc" categories="must-have, best-seller, special-offers, " ]');}
        ?>
    </div>

    I would love a solution like this:

    If a page is submenu under deals then show x, if a page is submenu under stores then show y. Otherwise show nothing.

    Who can help me out?

    Thanks in advance!

  • The topic ‘Different pages, different slider in header’ is closed to new replies.