DISCLAIMER: this post is older than one year and may not be up to date with latest WordPress version.

Do you use WordPress as a CMS instead of a blog? If yes, you’ll probably be interested to know how you can display a single post on your blog homepage.

Open your index.php file, and replace your current loop by this one (replacing the stickies category name by the category of your choice) by :

<?php if (have_posts()) : 
$my_query = new WP_Query('category_name=stickies&showposts=1');
while ($my_query->have_posts()) : $my_query->the_post(); ?>

That’s all! Only the latest post is displayed on your homepage.

Leave a Comment

Your email address will not be published. Required fields are marked *