Show only posts from one category?
-
I want my frontpage to display only posts from my ‘Blog’ category, and to list posts from other categories on another page. I’ve tried using the in_category(‘x’) check in the while loop for my theme, but it doesn’t seem to be able to tell the difference between the posts.
Edited code is as follows:
[code]<?php while (have_posts() && in_category('4') ) : the_post(); ?>[/code]Shows all of my posts, regardless of category, if set to ‘4’, shows nothing if set to anything else ??
Can anybody suggest as to how I can fix this?
Viewing 5 replies - 1 through 5 (of 5 total)
Viewing 5 replies - 1 through 5 (of 5 total)
- The topic ‘Show only posts from one category?’ is closed to new replies.