List wordpress scheduled posts

November 11, 2008 · Print This Article

Here’s a good idea to make your readers visit your blog more often, or suscribe to your rss feed:

What about listing the title of your scheduled posts?

Just paste the following code anywhere on your template where you want your scheduled posts to be listed.

You can change the max number or displayed posts by changing the value of showposts in the query.

$my_query = new WP_Query('post_status=future&order=DESC&showposts=5');
if ($my_query->have_posts()) {
while ($my_query->have_posts()) : $my_query->the_post();
$do_not_duplicate = $post->ID; ?>
<li><?php the_title(); ?></li>
<?php endwhile;

Your choice for site templates and wordpress themes


Got something to say?

You must be logged in to post a comment.