News:

Bored?  Looking to kill some time?  Want to chat with other SMF users?  Join us in IRC chat or Discord

Main Menu

Removing rank text

Started by Hathor, March 28, 2015, 09:10:06 AM

Previous topic - Next topic

Hathor

Hello,

I am trying to figure out how to remove everyones rank that shows as text in every message they post. I have rank images that i'd like to use instead, but with both the text AND image - it looks really dufus.

Illori

blank out or remove the name for the post count groups, this way you dont have to modify any files.

Hathor

#2
Quote from: Illori on March 28, 2015, 10:06:14 AM
blank out or remove the name for the post count groups, this way you dont have to modify any files.

That solved half the problem (Thanks!), but what about the non-post count groups like admin / mod?

[Edit: I did the same for the non-postcount based groups, and it works, but i can't use the forum group legend when using this method].

Steve

You could do this:

In theme/display.template.php find:

// Show the member's primary group (like 'Administrator') if they have one.
if (!empty($message['member']['group']))
echo '
<li class="membergroup">', $message['member']['group'], '</li>';


Change to:

// Show the member's primary group (like 'Administrator') if they have one.
// if (!empty($message['member']['group']))
// echo '
// <li class="membergroup">', $message['member']['group'], '</li>';
DO NOT pm me for support!

Hathor

Dangit,

I suspect i'll have to contact the theme author then, as i'm using the Dzine studio and when i look through ACP I cant find that template under that theme : /

Steve

Do it in the Default theme. That will take care of the theme you're talking about.
DO NOT pm me for support!

Hathor

Quote from: Steve on March 28, 2015, 12:36:15 PM
You could do this:

In theme/display.template.php find:

// Show the member's primary group (like 'Administrator') if they have one.
if (!empty($message['member']['group']))
echo '
<li class="membergroup">', $message['member']['group'], '</li>';


Change to:

// Show the member's primary group (like 'Administrator') if they have one.
// if (!empty($message['member']['group']))
// echo '
// <li class="membergroup">', $message['member']['group'], '</li>';


Yes! That did it!

Thanks a bundle! This was really starting to annoy me, but now it's working beautifully :)

Steve

DO NOT pm me for support!

Illori

just keep in mind that does not remove the post count group title from everywhere it appears.

Steve

Look at Illori raining on my parade.

j/k ... She's right of course. I should have pointed that out myself. ;D
DO NOT pm me for support!

Hathor

I noticed, but it removes them from the posts - where it was incredibly annoying. I find it hard to believe there isn't core functionality built in for this but as long as its doable, i suppose :)

Steve, as serious as cancer is, i really like your signature :p

Kindred

why would it be core functionality to remove that text?  That text is there on purpose :D
Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

Hathor

Quote from: Kindred on March 29, 2015, 12:38:56 AM
why would it be core functionality to remove that text?  That text is there on purpose :D

Why shouldnt the admin be able to decide if he wants to use text or image, or text and image? ;)

Illori

the admin can choose, they can leave the name blank and it will not show up anywhere. this also requires no coding changes.

Steve

@ Hathor - I like it too :P

And I agree, I wish it were a built-in option also. Like you, I use images that say what the group is so I never saw the point in having it in the mini-profile twice like where Illori's says 'SMF Friend' and has an image that says it.

And leaving it blank isn't really an option if you have multiple groups is it?
DO NOT pm me for support!

Illori

i have multiple post count based groups and none have a "name", does not cause a problem for me.

Steve

Sorry, I meant non-post count based.
DO NOT pm me for support!

Kindred

the admin CAN choose... an admin can use or design a different theme that doesn't include that section in display.template.php. :)
Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

Illori

Quote from: Steve on March 29, 2015, 09:41:11 AM
Sorry, I meant non-post count based.

i dont use that method for normal groups.

Hathor

Quote from: Kindred on March 29, 2015, 09:41:53 AM
the admin CAN choose... an admin can use or design a different theme that doesn't include that section in display.template.php. :)

To find an appropiate theme that does what i want without hiring someone to build it is difficult, and removing non-post based usergroup names make it trickier when setting access settings.

Advertisement: