wp_list_categories selected states only working 2 levels down
-
Hi all,
I’m playing around with the navigation with wordpress and it has really improved with 2.7. I basically have a single line of code to list all categories and their siblings in correctly formatted lists. Here is the line of code:
<?php wp_list_categories('show_count=0&title_li=0');
The only issue, is the selected classes. There only seems to be 2 levels of classes – current-cat-parent & current-cat, which means when I am down to the third level of the category hierarchy, the parent tab no longer has a class to show it is selected. Here is the HTML it is producing:
<ul id="topNavigation"> <li class="cat-item cat-item-1"> <a href="/">Main Parent</a> <ul class="children"> <li class="cat-item cat-item-7 current-cat-parent"> <a href="/">test category</a> <ul class="children"> <li class="cat-item cat-item-8 current-cat"></li> </ul> </li> </ul> </li> </ul>
I would like the parent category to be selected for all levels of sub-nagation. Is it possible to do this? I’ve been searching to no avail for ages and would greatly appreciate any help.
Thanks
- The topic ‘wp_list_categories selected states only working 2 levels down’ is closed to new replies.