Multiple loop question
I would like to have 4 posts on my front page: Feature, Photo of the week and two other most recent posts that aren’t those categories.
get_posts()works perfectly for the first two. Then when I run through the loop for the 2 most recent, I want to exclude any past photos of the week or features. Unfortunately, the setting for “number of posts to display” makes this a problem. How do I write the third loop to show 2 most recent posts that are not categorized by “Photo” or “Feature” and also aren’t the two posts above. If the 2 most recent posts are the current feature and the photo, then nothing shows with “number of posts to display = 2”.
Right now I am saving the post number of the photo and feature and skipping those. If
in_category()hits one of those, then it counts that as one of the posts to display. That is what I don’t want.
- The topic ‘Multiple loop question’ is closed to new replies.