View Full Version : How do I change a usergroup's title color and font weight?
edgeless
03-08-2013, 03:21 AM
My version is 4.2.0 and I'm currently using postbit_legacy format.
This should be such a simple thing to achieve (and it probably is). I'm trying to change the usergroup title colors (as they are displayed underneath the user names and above the avatars within posts). The method for changing the markup color for the user names within a usergroup is clearly documented among numerous posts here and quite easy to accomplish with the Usergroup Manager. But I can't seem to find a way to change the usergroup title colors and font weights. No matter what I've tried so far they remain black and un-bolded. Will someone please point me to the solution?
Thank you.
Ba'al
03-08-2013, 04:41 AM
Check here: https://vborg.vbsupport.ru/showthread.php?t=105598
--------------- Added 1362721989 at 1362721989 ---------------
The easiet way is to go to admincp>usergroup manager>the usergroup you want to change> html markup boxes and enter this(<font color="#8C1717"><i><b>) in the box on the left and this in the box on the right(</font></i></b>)
remember to change the hex code color i used to oneyou want to use
nerbert
03-08-2013, 04:54 AM
Figuring out all those css classes makes my head spin. I would jut go into the postbit_legacy template on line 33, <span class="usertitle">, and edit in an inline style attribute.
@Ba'al, he wants to change the user title mark up. That setting is for the mark up for the user name itself.
Ba'al
03-08-2013, 05:08 AM
Figuring out all those css classes makes my head spin. I would jut go into the postbit_legacy template on line 33, <span class="usertitle">, and edit in an inline style attribute.
@Ba'al, he wants to change the user title mark up. That setting is for the mark up for the user name itself.
Yeah, my bad, i brain farted lol I was just trying to edit my post with a "Nevermind" lol
edgeless
03-08-2013, 12:18 PM
Thanks for the replies...
Figuring out all those css classes makes my head spin. I would jut go into the postbit_legacy template on line 33, <span class="usertitle">, and edit in an inline style attribute.
But that would not specify for the different usergroups. I need the title colors to match the current colors of the name text for each group. I want it like this: Administrator Super Moderator Moderator, etc. How can I do that?
@Ba'al, he wants to change the user title mark up. That setting is for the mark up for the user name itself.
Yes, I had already changed the HTML markup for each usergroup sometime ago (although I used span tags). And the result was that each of the user names became the color of its respective usergroup and in bold font. But the usergroup titles still appears in black and are not in bold font.
--------------- Added 1362754956 at 1362754956 ---------------
I'm sure not having much luck finding a way to do this. Can anyone help, please?
Amaury
03-08-2013, 02:03 PM
<span style="color:[color here];"><span style="font-weight:[font weight here]"></span>
edgeless
03-08-2013, 02:11 PM
<span style="color:[color here];"><span style="font-weight:[font weight here]"></span>
But where do I put it? That's the same html that I put in the usergroup markup to make the user names colored. It does NOT affect the user titles. How can I change the colors of the user titles to match the group text colors?
Ba'al
03-09-2013, 04:08 AM
But where do I put it? That's the same html that I put in the usergroup markup to make the user names colored. It does NOT affect the user titles. How can I change the colors of the user titles to match the group text colors?
On our forum we only do it by request and the way i usually do it is i go into the members profile page in the admincp and add it there after adjusting it to allow html.
edgeless
03-09-2013, 06:50 PM
On our forum we only do it by request and the way i usually do it is i go into the members profile page in the admincp and add it there after adjusting it to allow html.
Yes, that way works per user. But I was hoping there would be a way to make the color and font weight/style stick as a default for all users created in a usergroup class, as there is with user names. I guess there may not be.
nerbert
03-09-2013, 08:36 PM
Here's a crude way of doing it with template edits.
In postbit.css add this to the bottom:
/* markup for administrators */
.postbit .group-6, postbitlegacy .group-6{
color:red;
}
in the postbit template find line 42 and modify as follows:
<div class="username_container">
<vb:if condition="$post['userid']">
{vb:raw memberaction_dropdown}
{vb:raw post.onlinestatus}
<vb:else />
<span class="username guest">{vb:raw post.username}</span>
</vb:if>
<span class="usertitle group-{vb:raw post.usergroupid}">
{vb:raw post.usertitle}
</span>
<vb:if condition="$post['rank']">
<span class="rank">{vb:raw post.rank}</span>
</vb:if>
{vb:raw template_hook.postbit_userinfo_left}
<vb:if condition="$show['reputation']">
<span class="postbit_reputation" id="repdisplay_{vb:raw post.postid}_{vb:raw post.userid}">{vb:raw post.reputationdisplay}</span>
</vb:if>
<vb:if condition="$post['userid']">
<div class="imlinks">
{vb:raw post.icqicon} {vb:raw post.aimicon} {vb:raw post.msnicon} {vb:raw post.yahooicon} {vb:raw post.skypeicon}
</div>
</vb:if>
</div>
for postbit_legacy do similarly for line 33
<div class="userinfo">
<div class="username_container">
<vb:if condition="$post['userid']">
{vb:raw memberaction_dropdown}
{vb:raw post.onlinestatus}
<vb:else />
<span class="username guest">{vb:raw post.musername}</span>
</vb:if>
</div>
<span class="usertitle group-{vb:raw post.usergroupid}">
{vb:raw post.usertitle}
</span>
<vb:if condition="$post['rank']">
<span class="rank">{vb:raw post.rank}</span>
</vb:if>
{vb:raw template_hook.postbit_userinfo_left}
<vb:if condition="$show['reputation']">
<span class="postbit_reputation" id="repdisplay_{vb:raw post.postid}_{vb:raw post.userid}" title="{vb:raw post.username} {vb:raw post.level}">
<vb:each from="reputationdisplay" value="row">
<img class="{vb:raw row.class}" src="{vb:stylevar imgdir_reputation}/reputation_{vb:raw row.posneg}{vb:raw row.imgext}" alt="" />{vb:raw row.rowend}
</vb:each>
</span>
</vb:if>
<vb:if condition="$show['avatar']">
<a class="postuseravatar" href="{vb:link member, {vb:raw post}}" title="{vb:rawphrase {vb:raw post['onlinestatusphrase']}, {vb:raw post.username}}">
<img src="{vb:raw post.avatarurl}" alt="{vb:rawphrase xs_avatar, {vb:raw post.username}}" title="{vb:rawphrase xs_avatar, {vb:raw post.username}}" />
</a>
</vb:if>
I think I have the CSS right so it works in postbit legacy (I don't use it). By the same method you can write CSS for any group you want.
edgeless
03-10-2013, 03:15 AM
Thanks nerbert! I'll give it a try.
ForceHSS
03-10-2013, 04:08 AM
This code has not been tested
In user title manager put this
<span style="color:gold;font-weight:bold;text-shadow: 1px 1px 10px gold;">Change this to what you need</span>
take a note of the colours in that code change to what you need
This code can also be added to usergroups user name HTML markup ( tested and works here)
But without the text
This will make the text glow
vBulletin® v3.8.12 by vBS, Copyright ©2000-2025, vBulletin Solutions Inc.