Thank you very much! That is what I was looking for.
But now, Category name and Number of posts is in the same row:
<li class="cat-item">
<a title="Show all posts form Category Name" href="/category">Category Name Posts: 52</a>
I would like to displey numbers under. Should I add </ br> somewhere?
I was thinking about definding different style for Category Name e.g. <h1> and different for Posts in Category e.g. <p>.
Something like that:
<div class="categories">
<ul>
<?php
$variable = wp_list_categories('title_li&echo=0&show_count=1');
$variable = str_replace( '</a>', ' ', $variable); //remove the closing </a> tag here
$variable = str_replace( '(', '<p>Posts: ', $variable);
$variable = str_replace( ')', '</p></a>', $variable); //insert the closing </a> tag after the number
echo $variable;
?>
</ul>
</div>
Any ideas?