WordPress.org

Ready to get started?Download WordPress

Forums

How to get rid of the loop? (2 posts)

  1. Sainty
    Member
    Posted 9 years ago #

    I want to get rid of the loop with out editing it through the admin panel. is it possible to edit just this code below to make it show only the latest post?
    ---
    <?php if (have_posts()) : while (have_posts()) : the_post();?>

    <span class="newsBIG">" title="Permalink" class="newsBIG"><?php the_title(); ?></span> <span class="copy"><font color="#BAB9B9"><?php the_time('F jS, Y') ?></font></span>

    <?php ($post->post_excerpt != "")? the_excerpt() : the_excerpt(); ?>

    <?php endwhile; endif; ?>

  2. moshu
    Member
    Posted 9 years ago #

    Wouldn't be easier to set the Reading Options to 1 post? :)

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.