I am working with categories (cities) and subcategories with the same menu (for example: cars, animals, houses).
Therefore right now my categories structure looks like this:
- London -- cars -- animals -- houses - Manchester --cars --animals --houses
The slugs for each subcategory (as it seems they have to be unique), are named like this
category_name + subcategory_name looking like
Now, I would like to use a different template for my main categories (cities) than for the subcategories (cars, animals, houses).
I've read this topic that suggest a way to do it, but there's a big problem with it: I would need to create as many conditions as subcategories I have within all categories.
This makes it unmaintainable.
The other option I found was to create use the theme
category-slug.php, but this would also imply that I have to create as many subcategory themes as subcategories in all sections.
Is there any other way to do it?