PDA

View Full Version : Usergroups coloring


FudgeBalls2002
03-12-2006, 01:58 PM
I know you can change the color of a certain usergroup's username but how do make the rest of their font that color like underneath their avatar where all their info like age and such is in the postbit. I've seen it done on several vb boards. I tried just not putting end tags and it works but on the whos' online list the next person name, the comma after it is the color of my font.

007
03-12-2006, 05:45 PM
<a href="https://vborg.vbsupport.ru/showthread.php?t=110025" target="_blank">https://vborg.vbsupport.ru/showthread.php?t=110025</a>

FudgeBalls2002
03-12-2006, 05:53 PM
That wasn't my question.
http://www.gopednation.com/forum/showthread.php?t=207930
Look at the first person who posted, his entire postbit is yellow, not just his name. I want to achieve this.

ZacUSNYR
03-12-2006, 06:02 PM
I don't see any reason why you can't throw an if / else into postbit or postbit_legacy for the span class.

FudgeBalls2002
03-12-2006, 06:10 PM
I'm kind of new to this, can you write the clause and tell me where I have to put it?

007
03-12-2006, 07:08 PM
Oh, ok I misread your question. You can do this easily with:

<if condition="$post[usergroupid]==X"><font color ="#XXXXXX"></if>

<!-- the text you want to be a different color -->

<if condition="$post[usergroupid]==X"></font></if>

There are many variations of how you can do it with conditionals, but that is the most basic way.

FudgeBalls2002
03-12-2006, 07:13 PM
Thanks, I'm still alittle confused on where to enter that. For example, I want the admin's postbit a certain color and the rest of the usergroups default. I would just copy and paste the entire postbit into <!-- the text you want to be a different color --> and set the appropriate id for admin usergroup. Then what's the 2nd if condition for, what goes there?

007
03-12-2006, 07:39 PM
The second condition is just to close the </font> tag if the fist is opened. Put the same usergroup id there. :-)

You don't need to copy and paste into that middle area. Instead, just take the first condition above and place it where the XXXX is below (based on the default postbit legacy template):

<tr valign="top">
<td class="alt2" width="175">
XXXX
<div id="postmenu_$post[postid]">
<if condition="$show['profile']"

Then put the second one:

$post[msnicon] $post[yahooicon] $post[skypeicon]</div>
</div>
XXXX
</td>

FudgeBalls2002
03-12-2006, 08:27 PM
Thanks, worked perfectly

007
03-12-2006, 09:29 PM
No problem. :-) Good to hear.