Support Forum

Remove posts counts that comes in () next to admin names at the footer

NS Nev shan
Nev shan
Member

I would like to remove the posts counts that comes in () next to admin names at the footer. Please advice. Below is the email I received but unsure on how to do this

 

Not directly, no…  But you can use a filter on the display to remove them… do you know to use standard wp filters?  if so, the filter would be:  sph_AdminsList

then you could just use a remove the post counts…  if you need more help with the details, please open a topic in the support forum…

 

Thanks

3 Answers

New Answer

YS Yellow Swordfish
Yellow Swordfish
Member

We are not ignoring you but this is going to need some regular expression work and I am just hopeless at that. We need Mr Papa for this and he wont be around until much later on…

MP Mr Papa
Mr Papa
Member

does that mean you are familiar with the wp api and using filters?  or do you need an explanation on that too?

MP Mr Papa
Mr Papa
Member

you will want to add something like this to your spFunctions.php template file of the sp theme you are using:

add_filter('sph_AdminsList', 'my_adminlist');
function my_adminlist($out) {
    $out = preg_replace('# (([0-9]+))#', '', $out);
    return $out;
}

as always, we strongly recommend you have your own theme instead of editing one of ours to keep from losing changes on upgrades… see:  http://codex.simple-press.com/codex/themes/theme-basics/creating-a-theme/