skip *and* show a post?
-
I’ve written a custom database query t display posts by meta value. I’m having an issue though – some of my posts are in more than one category, and because of this, it’s displaying the post once for each category. I only want it to display once.
For example, if the post is in “books” and “horror”, then the post shows up twice on the page.
Would anyone know how to get it to show up only once? I’ve tried “if(in_category())” to change it – but because it’s in the category I *don’t* want to show, the category I *do* want to show also disappears because it’s in the other category, as well. I’m sure it has to do with the “foreach” statement, but I’m not sure how to flag it so it skips the one category, but displays the other.
The topic ‘skip *and* show a post?’ is closed to new replies.