How To Show Your Schedule Blogs On Your Blog Home Page


In our last post we have discussed about ‘How to Schedule Your Post in WordPress. But it could be better if we show our future upcoming posts in our website. So, all of our readers will know what they will have in future posts. We can’t find this feature more in WordPress premium themes. So, we have described here the way to create this feature in any wordpress self-hosted site.

At first you schedule your posts for future dates. We would like to show future posts in home page of our example website, beneath of the current posts. So, we are coding on index.php.  Now open index.php or wherever you like to show the future posts list. Copy and paste the following code between <?php endif; ?> and </div><!– #content –>

<div style="background-color:#CCCCCC; color:#003366; border:1px solid #CCCCCC; border-radius:10px 10px 10px 10px; 
padding: 3px; font-size:larger;">

<?php query_posts('posts_per_page=3&post_status=future'); ?>

<?php if ( have_posts() ) : ?>

<div align="center" style="background-color:#003366; color:#FFFFFF; border:1px solid #003366; border-radius:10px 10px 0 0;"><strong>Upcoming Blog</strong></div>

<?php while ( have_posts() ) : the_post(); ?>

<strong><?php the_title(); ?></strong></br>

<span class="datetime"><?php the_time('j. F Y'); ?></span></p>

<?php endwhile;

else: ?>

<div align="center" style=" height:auto; margin-top:25px;"><p>No Upcoming Blog.</p></div>

<?php endif; ?>



In above code you can find a parameter posts_per_page=3 which limits the number of posts being displayed. I preferred to show 3 posts under the ‘Upcoming Blog’. But we can change that number of scheduled posts we want to show our users. If we want to show 10 posts under ‘Upcoming Blog’ the code will be posts_per_page=10. So, try  to show your upcoming blogs on your blog site whenever you want.

If you find this article helpful, you can connect us in Google+ and Twitter.

Enter your email address:

Delivered by FeedBurner

Leave a Reply

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