[SOLVED] How to add a post counter to the category menu
I posted questions to add a counter in the categories menu, for each category, and I finally found a way to do it, with the help of the forums.
When it's finish it's pretty easy, you can see the result on my blog : http://www.radiatorhymn.com you just have to modify with the editor the bfa_hor_cats.php and recognize and replace the following line : (which activate the counter but display it under the menu) $list_cat_string = wp_list_categories('&show_count=1&orderby=' . $sort_order . '&order=' . $order . '&title_li=&depth=' . $levels . '&exclude=' . trim(str_replace(" ", "", $exclude)) . '&echo='); then after all the preg_replace lines, add these two ones : (which include the counter with the name of the category) $list_cat_string = str_replace("</a>","",$list_cat_string); $list_cat_string = str_replace(")",") </a>",$list_cat_string); done sorry for my poor english, I'm french... ah ah |
All times are GMT -6. The time now is 07:57 AM. |
Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.