Created
February 7, 2013 16:11
-
-
Save INDIAN2020/4731987 to your computer and use it in GitHub Desktop.
post divider
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
Add post divider in between two posts or more | |
Add this snippet right before the closing of the loop to auto insert a post divider “div” that you can style using the “post-item-divider” class. | |
*/ | |
<?php | |
if (($wp_query->current_post + 1) < ($wp_query->post_count)) { | |
echo '<div class="post-item-divider">Post Divider</div>'; | |
} | |
?> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment