• Resolved sophiavancouver

    (@sophiavancouver)


    I’d like to modify my archive.php template so that it shows a listing of the child categories for that category, no matter what category page I happen to be on. I’d like to avoid having to do a separate archive template for each category that has a subcategory and just use a function that always returns the child of the current category.
    WP_list_categories needs to know the ID of the category page you’re on and doesn’t seem to take a variable.

    I’m hoping there’s a function that does this, but I haven’t found one yet. Failing that, is there any way to pass the current id of the category page you’re on to wp_list_categories so that this will work?

    Does anyone know how to do this?

Viewing 3 replies - 1 through 3 (of 3 total)
Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘List children of current category’ is closed to new replies.