WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

A new site i'm making is going to use extensive use of the categories, so here's what i'm trying to accomplish:

Main Category Name (Link)

List of Sub Categories (All Links)

When i'm on a sub-category page I want it to look like the Main Category page just with the sub-categories highlited.

Is that possible?

share|improve this question
up vote 0 down vote accepted

That's damn simple, see here: http://codex.wordpress.org/Function_Reference/get_categories . The sample downhere should work:

$kids = get_categories(array('child_of'=>get_query_var('cat'))); 
share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.