WordPress.org

Ready to get started?Download WordPress

Forums

Show Latest Post in Category X (4 posts)

  1. TomJohnson
    Member
    Posted 6 years ago #

    I want to make it so that a certain category (category X) shows just the latest post in that category. And here's the clincher: I want the latest post to show itself in the single post view by default, so that it will contain the back and forward navigation links. How would I do that?

  2. Anonymous
    Unregistered
    Posted 6 years ago #

    This isn't really very helpul to u, but i wonder if u could help me.

    I want index.php to display the LATEST POST - in full, no MORE tag. And I want the sidebar to display shortened versions of the last 3 entries (excluding tha latest entry).

    I've got:

    <?php (query_posts('p=0')); ?>

    <?php the_post(); ?>

    <span id="a1"><?php the_time('l, j F Y') ?></span>

    <h3><?php the_title(); ?></h3>

    <?php the_content('How do I get rid of this MORE tag?'); ?>

    for the main page.

    I don't really know where to go from there. I also would like the sidebar to display the latest entries, INCLUDING the most recent when on a page other than index.php but that can come later.

    If you have any thoughts, please let me know.

  3. dmak
    Member
    Posted 6 years ago #

    If there is a plugin for this, please feel free to post. Otherwise, I prefer a php command.

  4. TomJohnson
    Member
    Posted 6 years ago #

    sorry dmak, i don't know how to make the query show the latest post in full. the read more tag only appears if you stick it in your blog post. are you aware that there's a the_content and the_excerpt view? if you remove the read more tag from your posts, you could show the the_excerpt view that automatically shows an excerpt, similar to the read more tag. also, there's a plugin called evermore that inserts the read more tag automatically in every post.

Topic Closed

This topic has been closed to new replies.

About this Topic