WordPress.org

Ready to get started?Download WordPress

Forums

Looking to offset "most recent posts" (2 posts)

  1. jonblazn
    Member
    Posted 5 years ago #

    Hi-
    I'd like to offset my most recent posts section that I have in my footer to show the 6-12th most recent posts rather than the most recent 6 posts. This is because my blog already displays the 6 most recent posts on the index page and I don't want it to be too redundant.

    Right now it looks like this:

    <div class="foot-info" style="width:30%; float:left; margin-right:10px;">
    					<h2>Most Recent</h2>
    					<ul>
    						<?php get_archives('postbypost', 6); ?>
    
    					</ul>
    				</div>

    Anyone know what I need to add to offset the most recent posts that display by 6?

  2. yoshi
    Member
    Posted 5 years ago #

    get_posts would be more suitable for that purpose.

    The first example in the codex page is exactly what you are looking for.

    BTW, get_archives has been deprecated and now we should use wp_get_archives instead.

Topic Closed

This topic has been closed to new replies.

About this Topic