• Hello,
    I’m trying to edit the index.php on this theme, so there is static text on the home page, page text if it is a page, and post text if it is a post.

    Here’s what’s on the index.php so far:

    <h2 class="title">Home Page Item</h2>
    <div class="article">
    Only show when it's on the home page
    </div>
    </div>

    <?php if (have_posts()) : ?>
    <?php while (have_posts()) : the_post(); ?>
    <?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title(); ?>"><?php the_title(); ?></h2>
    <div class="blog" id="post-<?php the_ID(); ?>">
    <h2 class="title"><a href="
    <div class="postmetadata">posted <?php the_time('F jS, Y') ?> by <?php the_author() ?><!-- <?php the_category(', ') ?> --> <strong>|</strong> <?php edit_post_link('Edit','','<strong> |</strong>'); ?> <img src="https://www.hannahscreekrevival.com/jaymeblackmon/wp-content/themes/jayme/images/speech_bubble.gif" /> <?php comments_popup_link('No Comments »', '1 Comment »', '% Comments »'); ?></div>
    <div class="article">
    <?php the_content('Read the rest of this entry &raquo;'); ?>
    </div>
    </div>

    <?php endwhile; ?>
    <?php else : ?>
    <h2 class="center">Not Found</h2>
    <p class="center">Sorry, but you are looking for something that isn't here.</p>
    <?php include (TEMPLATEPATH . "/searchform.php"); ?>

    <?php endif; ?>

    What do I enclose the first little bit so when the user is on the first page, he only sees that but not the posts?

Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
  • The topic ‘Need help with conditional tags’ is closed to new replies.