free tuts

By default number of posts in certain category comes included into parenthesis. Sometimes we want to remove it and style post number count. To do that we need to add simple function to page or sidebar (depends where we want to populate category list):


Depends, whether we want to display categories with zero posts or we don’t + whether we want to display subcategories or we don’t.

Full list of parameters is published in WP Codex.

Now we just style list itself and the span we defined for post number counter.

And visual result is:


And another version, showing both parent and children (sub) categories:


View it live