• High, I’m trying to add breadcrumbs to my site for categories and sub-categories. In other words, if you click a post in Category A, Sub Category B, I’d like it to say at the top:
    Category A >> Sub Category B

    I tried adding this to category.php:
    <h2 class=”pagetitle”><? if (get_category_parents(the_category_ID(FALSE))) { echo get_category_parents(the_category_ID(FALSE)); }?><?php echo single_cat_title(); ?></h2>

    But that both always returns the current category as it’s own parent if your already in a top-level category, and seems to work strangely with multiple sub-categories (you get Category A >> Sub-Category B >> Sub-Category C when you should get Category A >> Sub-Category C)

    Any ideas?

Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Cat and subcat breadcrumbs’ is closed to new replies.