The forum of the forums
Would you like to react to this message? Create an account in a few clicks or log in to continue.

Customize usernames according to group

2 posters

Go down

Tutorial Customize usernames according to group

Post by Ange Tuteur March 10th 2014, 10:39 am

Customize usernames according to group


The following trick will allow you to customize the usernames of the members of your Forumotion forum, according to the group which they belong.

Here is an example of what you can do :
- With a member of the group "Support Moderators" : Customize usernames according to group Captu364
- With a member of the group "Administrators" : Customize usernames according to group Captu365
- Overview of the "Who's Online" :
Customize usernames according to group Captu366

Modifying the stylesheet

Go to Administration Panel ► Display ► Colors ► CSS stylesheet. Copy and paste the following code :
Code:
a span[style="color:#000000"] strong {
    background:url(https://2img.net/i/fa/empty.gif) no-repeat;
    padding-left:**px;
}

Modifications :
In the code above, so that this trick works, you must modify :

- span[style="color:#000000"] : replace #000000 with the color code that corresponds to the group you wish to modify. You can find this code in Administration Panel ► Users and Groups ► Groups ► Groups administration.

- background : corresponds to the image that is inserted before the username. Here, you must modify the URL https://2img.net/i/fa/empty.gif with the URL of your image.

- padding-left : allows you to add a left margin to the username to show the image. Here, you must modify **px : these ** corresponds to the width of your image. If the image is 16 pixels width for example, it would be : 16px.

More customization...

Still using the selector given above and changing the color of the group :
Code:
a span[style="color:#000000"] strong

You can customize as you wish with the usernames of your members according to their group. For example : a border, give them a background, a particular font, a shadow…

Ange Tuteur
Ange Tuteur
Forumaster

Male Posts : 13207
Reputation : 3000
Language : English & 日本語
Location : Pennsylvania

https://fmdesign.forumotion.com

Back to top Go down

Tutorial Re: Customize usernames according to group

Post by Ape February 5th 2020, 7:22 pm

This code was updated to fit in with the new HTTPS address
updated on 02.05.2020 by APE
NOTE: Thanks to an update you will not see this in all the right places when logged out.
BUT it will work fine when logged in.


Customize usernames according to group Left1212Customize usernames according to group Center11Customize usernames according to group Right112
Customize usernames according to group Ape_b110
Customize usernames according to group Ape1010
Ape
Ape
Administrator
Administrator

Male Posts : 19452
Reputation : 2012
Language : fluent in dork / mumbojumbo & English haha

http://chatworld.forumotion.co.uk/

Back to top Go down

Back to top

- Similar topics

 
Permissions in this forum:
You cannot reply to topics in this forum