• I currently have wordpress set up to show the last 10 posts on the main page. But I’m begining to post more than 10 posts a day. I’ve tried increasing the amount of posts on the main page to 15, but the pageload time was not good. I’m wondering if there is a way through a plugin, hack, or even template, to make it so that I can show my first 10 posts like they are now, and then just the linked headlines for the next, let’s say 20 posts. Is there a way to do this?

Viewing 6 replies - 1 through 6 (of 6 total)
  • Yes, you do it by adding another loop, like so:

    <?php query_posts('showposts=20&offset=10'); ?>
    
    <ul>
    
    <?php while (have_posts()) : the_post(); ?>
    
    <li><a href="<?php the_permalink(); ?>"><?php the_title(); ?></a></li>
    
    <?php endwhile; ?>
    
    </ul>
    Thread Starter orfilms

    (@orfilms)

    okay one more question. Is it possible to list the posts by date. For instince

    Friday, January 12th 2007:
    * ………………………
    * ………………………
    * ………………………
    * ………………………
    * ………………………
    * ………………………

    Thursday, January 11th 2007
    * ………………………
    * ………………………
    * ………………………
    * ………………………
    * ………………………

    Wednesday, January 10th 2007
    * ………………………
    * ………………………

    ?

    Thread Starter orfilms

    (@orfilms)

    And how can i format this so that that loop only appears on the main page?

    Thread Starter orfilms

    (@orfilms)

    Anyone?

    If you put the code told above, in your theme’s index.php file (aka Main Index Template) then it will only be on the homepage.

    If you wanted it on other pages you would put it also in Single Post Template, Category.php, and maybe some Archives template(s).

    I don’t know about how to sort it by date but it can be done

    Thread Starter orfilms

    (@orfilms)

    I don’t have a single post template, i just have a main template

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Extra headlines?’ is closed to new replies.