WordPress.org

Forums

"Recent Posts" widget hack (3 posts)

  1. railcrew
    Member
    Posted 5 years ago #

    I'm using the wp default widget for "Recent Posts". how do I edit it to show the second post in line first (the last one just before the newest post) instead of the newest most recent post first? I'm pretty sure it can be done, I've seen it in Theme settings before I think...

    I'm using "SilverLight".01 theme

  2. railcrew
    Member
    Posted 5 years ago #

    I noticed the Theme rsidebar template has it set as I want (numberposts=10&offset=1) (I think thats the right code?) but I'm not using the theme recent posts, I'm using the WP widget recent posts. I've looked all over my templates and can't find where to edit it as I want it.

  3. railcrew
    Member
    Posted 5 years ago #

    Ok. not a big code genius here, but like I said in the second post, I figured how My theme deals with recent posts in the sidebar
    (rsidebar.php)
    <?php
    $myposts = get_posts('numberposts=10&offset=1');
    foreach($myposts as $post) :
    ?>
    and I know that when you add widgets (twitter,etc...) to the sidebar, it overrides the sidebar code and you must then add each widget, (recent, archive, etc...) from available widgets. The widget options does allow you to state how many recent posts you would like to display, but doesn't allow you to remove the most recent (offset=1) I've looked every where I can't find where to hack it.

Topic Closed

This topic has been closed to new replies.

About this Topic