Great job Otto42 … I put it in my sidebar ( not widgettized ) and it works very well.
This is my use of this :
I added depth=1 in wp_list_categories , so I have a Cat menu without children cat.
Then I added :
if(is_category()|| is_single()){global $wp_query;
$cat_obj = $wp_query->get_queried_object();
$current_name = $cat_obj->name ;
$current = $cat_obj->term_id;
?><h4><?php echo $current_name . “Has ID =”.$current;
?></h4><?php echo “and has subcategories as follows :”;
wp_list_categories(‘orderby=name&show_count=1&title_li=&use_desc_for_title=1&child_of=’. $current);}
That show me the subcategories of current cat ….
Great !
Thanks
Skyppyno