Custom Username colours
This is my first posted template edit so be gentle.
It comes courtesy of the username and font hack by gio~logist. This mod will allow you to define a list of colours for your users to pick from instead of them having to use hex codes. There is also the option of just letting particular user groups use this. STEP 1 Goto User Profile Fields > Add new user profile field. Select Single Selection Menu. Title: Custom Username Colour Description: Select a custom username colour. Select your colours from the long list at http://www.w3schools.com/HTML/html_colornames.asp and enter them into the Options box. One colour per line. Once you're done, save it and make a note of the field number STEP 2 Edit your Postbit template. Find PHP Code:
div id="postmenu_$post[postid]">
PHP Code:
<div id="postmenu_$post[postid]">
STEP 3 If you want to display this for certain usergroups; Go to your Styles & Templates and select the userfield_select_option template. Replace it with: PHP Code:
<if condition="THIS_SCRIPT != 'profile' OR (!in_array($profilefield[profilefieldid], array(A, B, C)) OR is_member_of($bbuserinfo, 1, 2, 3))">
Select the userfield_wrapper and replace that with the following: PHP Code:
<if condition="THIS_SCRIPT != 'profile' OR (!in_array($profilefield[profilefieldid], array(A, B, C)) OR is_member_of($bbuserinfo, 1, 2, 3))">
My coding abilities at best can be described as amateur but I'll try to help with any problems. Download
custom usernames.txt (2.7 KB, 195 downloads) Screenshots |