Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- // Get the term id first
- $term = get_term_by( 'slug', get_query_var( 'term' ), get_query_var( 'taxonomy' ) );
- $currentTerm = $term->term_taxonomy_id;
- // This is how you'd use it in your template
- wp_list_categories( array(
- 'taxonomy' => 'YOUR_TAXONOMY',
- 'current_category' => ( isset($currentTerm) ) ? $currentTerm : null
- ));
- ?>
Add Comment
Please, Sign In to add comment