Wordpress latest posts plugin?

Associate
Joined
30 Nov 2003
Posts
1,614
Is there a Wordpress plugin that will output the latest blog posts so that I can use that on my homepage? Or any other way of doing it?

Basically I have Wordpress installed in /blog/ on my website on on my homepage I want to display a snippet of say the last 5 blog posts...:)
 
Code:
<?php wp_get_archives('title_li=&type=postbypost&limit=10'); ?>

edit: oops you said snippet. That won't get the snippet!

Do you want a plugin so you don't get your hands dirty or are you able to code?

Code:
<?php
$recent = new WP_Query();
$recent->query('showposts=4');
if($recent->have_posts()) : while($recent->have_posts()): $recent->the_post();
?>
<!--whatever html structure you want to put here to get the_title() the_permalink() and the_excerpt() for each of the members of $recent->the_post()-->
<?php endwhile ?>
<?php else : ?>
<p> Nothing to see here. Move along </p>
<?php endif ?>
 
Last edited:
Back
Top Bottom