Show Available Taxonomy List with Current Category

As you can see from the image, I am listing all categories and the cities (taxonomy list).
enter image description here

What I want to do is :

Read More

If Car classifieds is selected on cities list show the city name which has car classified on that city. That means if 2 Car Classified is on London should show ‘London (2)’ (not total number). It is like filtering action.

I have something like

$cat_id = get_category(get_query_var('cat'))->slug; 
wp_list_cats( 'hide_empty=1&hierarchical=1&order=ASC&show_count=1&taxonomy=location&title_li=0&cat=$cat_id' );

Which doesnt work. I feel I am really close to solve this but couldnt manage to do it.

Related posts

Leave a Reply

1 comment

  1. I’m not hundred percent sure but I think the widget in scribu’s plugin, Query Multiple Taxonomies, works exactly as you described. You can find plenty of resources on the subject on his blog.

    This plugin lets you do faceted search using multiple custom taxonomies.

    It has a drill-down widget with multiple display modes.

    Said widget is easily customizable via template files (no PHP knowledge required).