Multiple Category and Single-Cat Templates
-
Hi
I am hoping someone might be able to suggest a more elegant approach. I feel like I am using a hammer to solve a problem.
Lostwithiel
I am using WordPress to power a directory listing for the above site. If you click on Food and Drink you will notice that the left hand sidebar links change to reflect that category id. I have created a category-??.php template for the category. I have also created a template for all sub-categories of that category along with single-cate-??.php for each single post.
This approach has brought up two issues. Firstly, the amount of files. I currently have about forty cat files and about 35 single-cat files – it seems excessive and secondly, if a new category is created by a user I will have to create a new cat and single-cat file.
Any ideas please?
Thanks
Rich
The topic ‘Multiple Category and Single-Cat Templates’ is closed to new replies.