Last active
October 2, 2018 12:11
-
-
Save lamberger/780ac7eae0d4fac18bb9235b88cb3865 to your computer and use it in GitHub Desktop.
Last post in loop
This file contains hidden or 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
| <?php | |
| if (($arr_posts->current_post +1) != ($arr_posts->post_count)) { | |
| echo 'If not the last do something'; | |
| } | |
| if (($arr_posts->current_post +1) == ($arr_posts->post_count)) { | |
| echo 'If last do something else'; | |
| } | |
| ?> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment