Site logo

Archived topic

Display subcategories on parent category page.

7 replies · Started by Andrew on September 2, 2017

Viewing posts 1–8 of 8

Hi, great theme!

Any idea how to achieve this: On the parent category pages, there is a grid display of the subcategories with their category title, image, description and link.

Sure, it's quite a bit of customization but I'd like to achieve it with GeneratePress.

Any pointers would be great!

Hi Andrew,

This will require lots of customizations for sure.

Are you able to provide an example of what you are going for? Thanks!

Well, http://lifecycle.pash.space/cycles/

You can see from the menu that Cycles is a page with three dropdown tabs that are categories that are actually subcategories of a parent category also called Cycle. I'd like to use the category page rather than a static page to display the three subs. I'd like it to be automatic so that every parent category page does that.

That would involve some decent customization to the category page template. You're likely better off using the static page approach - it gives you much more control.

OK, yes, sure - but a client wants it all done automatically.

When a category page is displayed, can you point me towards the relevant php files please.

category.php is the template file for categories.

category-slug.php is the template you would use for specific categories - slug being the name of the category.

Make sure to upload these files into a child theme :)

Hi there,

Getting confused, slightly - I can see no category.php file in the GP theme files.

Only the one in wp-includes.

Please advise!

We use archives.php, which works for categories as well as other archive pages. You can use archives.php as well, or use category.php which is more specific.

This archived topic is closed to new replies.