I cannot figure this out -- need to display only the category of the current post on the index, no matter what category that may be. If anyone has any suggestions that'd be great.
I cannot figure this out -- need to display only the category of the current post on the index, no matter what category that may be. If anyone has any suggestions that'd be great.
Where on the index?
What is it what you want to achieve? try to give more detailed info...
Sorry, here ya go:
On the index page of the blog, I would like to ONLY display the category of the most recent post. So if I post category 6, it should only display posts of that category. If I then do a post of category 3, it would no longer show category 6, only category 3. And so on...
Basically the blog will have a rotating identity on the index page (I have a different header image for each category too), and this will keep older/different category posts from showing up there.
Hopefully that makes more sense.....?
That first sentence should say: Display only POSTS IN THE SAME CATEGORY as the current post.
Yes, it does.
However, I don't remember any solution for this kind of "rotating" display of categories.
This search also didn't bring up many useful threads;
http://wordpress.org/search/display+last+updated+category?forums=1&p=2
Anyone else have a good way to do this? Perhaps one can get the category of the current post and omit it from the loop using a variable somehow? My php is useless.
This topic has been closed to new replies.