WordPress: Display Recent Posts Anywhere

I wanted to display the titles of recent blog entries on my start page.
Here’s the solution I came up with:

<ul id="recent_entries">
<?php get_archives('postbypost', '5', 'html', '', '', FALSE); ?>
</ul>

'5' specifies the number of posts to be displayed.
Just a little CSS styling for the list (#recent_entries li {...}) and that’s it.

Wordpress: Recent Posts

One Response to “WordPress: Display Recent Posts Anywhere”

  1. I really enjoyed reading this article, keep on writing such interesting articles.

Leave a Reply

Your Data

XHTML: You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>

What do you want to say?