Creating my WordPress author.php template page and ran into a little roadblock. I want to be able to separate all the Author’s posts by the parent category they are in. For example, I have these major categories of posts: ‘Books’, ‘Audio’, ‘Video’, ‘Curriculum’. On the author page, I want those overarching categories to be the header of each section and then the posts related to that section listed under the header.
Is the only way to do it to run multiple loops or is there a more efficient way?
Thanks!
Allan
You need to keep the file name author.php so you get that slug and link, but remove the standard WP loop and use a new query for each category, like this:
This can be used multiple times in a page template without conflict. Change
showposts=-1to 1 for one post, 10 for ten posts, etc. -1 shows all.Use html to arrange the output of those loops into columns.