How to Exclude Latest Post from the WordPress Post Loop

Excluding newest posts from the loop and/or offset posts within the loop is likely one of the issues that is useful when enhancing or designing themes. On this article we’ll present you ways you should utilize the offset parameter in wp_query operate to exclude newest posts from the WordPress publish loop.

First you have to to search out the loop that you’re working with. Then you have to so as to add the next parameter:


This question is telling the loop to solely show 5 posts which comply with the newest publish (1). The vital half on this code is “offset” and this magic phrase is doing the entire thing.

Your loop code ought to seem like:

if ( have_posts() ) : whereas ( have_posts() ) : the_post();

Download The WPSaviour App Now

Related posts
Beginner’s GuideBest WordPress PluginsBlog

9 Best Social Proof Plugins for WordPress & WooCommerce (2020)


How To Disable The WordPress User Admin Toolbar


WordPress Front Page vs Homepage


5 Things You Must Avoid Doing in WordPress

Leave a Reply

Your email address will not be published.

Pay in your preferred currency
Indian rupee