• Hi,

    I am trying to make this category & subsequent layout disappear if you are not on the page id==3:

    <?php $temp_query = $wp_query; ?>
    <?php if($page_id==3)  query_posts('cat=5&showposts=3'); ?> 
    
    <div id="rss_outer"><div id="rss_title"><h2>Latest Industry News</h2></div>
     <?php while (have_posts()) : the_post(); ?>
      <div class="post" id="post-<?php the_ID(); ?>">
        <h3><a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title(); ?>"><?php the_title(); ?></a></h3>
        <?php the_excerpt(); ?>
      </div>
    <?php endwhile; ?>
    <div id="spacer"></div></div>

    This makes the content disappear but not the layout. In other words the header & the box that the content appears in is still there on the pages that do not have the page id==3.

    How can I alter this code to make the lot disappear??
    Phil

  • The topic ‘Content disappearing but not my layout!!’ is closed to new replies.