Forums


Theme Lab Forums » Announcements and Updates

Coditional Sidebar display?

(2 posts)

  1. ollep
    Member

    Hi Leland

    I believe I saw an article here about “conditional display” in sidbar? Or was it at the WP page?

    Anyway, I want to alter the sidebar display on the different pages.
    How do I go about doing that?

    Thanks!!!

    Olle…

    Posted 1 month ago #
  2. Leland
    Key Master

    You could use the conditional tag is_page('your-page-slug') in the sidebar. For example, on the about page you would do this.

    <?php if (is_page('about')) { ?>
    Put your about page code here
    <?php } ?>
    Posted 1 month ago #

RSS feed for this topic

Reply

You must log in to post.

Recent Comments

  • Leland: No problem, and I like what you did with the theme! Looks great.
  • Nick: Yep, just got it. I removed this: <a href=”">Home Thanks!
  • Leland: Go into your header.php file and remove the following. <li<?php if ( is_home() or is_archive() or...
  • Nick: Hi, Thanks, but the problem is that there’s still a “Home” page that is forced to say as the...
  • Leland: @Nick: Have you read this? http://www.themelab.com/2008/0 4/28/you-dont-need-a-blog-on-y our-front-page/

About The Author

Welcome to Theme Lab. My name is Leland, and I run the place. I write all the tutorials and code all the themes you see here on the site.

For more information about me, feel free to read the about page. If you want to drop me a message, feel free to contact me.

Interested in advertising on Theme Lab? We have advertising available at very reasonable rates. Head on over to the advertising page for further details.

Please read our Privacy Policy and Terms of Service in regards to theme usage.

© 2008 - Theme Lab - Powered by WordPress