Is there a way to make a single template that applies to a category and all its child templates?
Thanks!
Is there a way to make a single template that applies to a category and all its child templates?
Thanks!
I am not 100% sure, but it's worth to take a look at this thread:
http://wordpress.org/support/topic/39740
I would assume you just have to use a category template.
Hope that helps you,
Lelia Katherine Thomas
http://www.leliathomas.com
Maybe I misread the OP, but seeing the words single template I thought it is about the single post view. In which case the category template doesn't work as desired.
What I'm trying to do is use templates with the proper names (category-#.php where # is the cat ID) to cover each of several categories, but also their child categories. Child categories have their own cat ID numbers, so I'm having trouble making a child use it's parent template.
For example:
-------------------------
ID Name
-------------------------
1 Mom Category
2 -- Little Billy Sub-Category
5 -- Little Suzi Sub-Category
3 Dad Category
4 -- Baby Francis Sub-Category
-------------------------
In the above circumstances, I want to create two category specific templates--category-1.php (Mom Category) and category-3.php (Dad Category). These will apply to Mom and Dad, respectively. However, I also need Mom's category-1.php to apply to her children, Little Billy Sub-Category (cat ID 2) and Little Suzi Sub-Category (cat ID 5). Then Dad's category-3.php template covers the Dad Category (cat ID 3) AND Baby Francis Sub-Category (cat ID 4).
I've got multiple writers working on the system, each assigned to a parent cateogory. They will be adding and removing their sub-categories as needed, but must rely that their sub-categories and individual post pages will use the assets (template, graphics) of their main or parent category.
Any help on making this one work?
Thanks!
I'd love this too - anyone get it to work?
I am not sure if this is what you are looking for, but I built a similar system for my static pages some time ago.
See this link: <http://brams.dk/technotes/wordpress/my-first-plugin/> - you should find explanation in the php file as well.
Kind regards
Torben Brams
not really what I'm looking for but could be helpful - that will allow me to do some of what I wanted to do.. :) thanks
This topic has been closed to new replies.