I'm sure this should be an FAQ, but how do I tweek the forums so that posts made by mods have a different background colour to those made by non-mods ?
Apr 27, 2004, 3:41 PM
Staff / Moderator (2198 posts)
Apr 27, 2004, 3:41 PM
Post #2 of 3
Views: 2817
You can use the "post_user_is_moderator" template tag to identify whether the post was made by a moderator (NOT an administrator, unless the administrator is also entered in the list of forum moderators). Edit the 'include_post_display.html' template, and look near the top (about three lines after the end of the description) for the <table... tag - it contains:
bgcolor="<%odd_color%>"
Change this to:
bgcolor="<%if post_user_is_moderator%>red<%else%><%odd_color%><%endif%>"
Obviously, change red to whatever background colour you want. If you want the changed colour for administrators' posts as well, change the '<%if ...%>' to '<%if post_user_is_moderator or user_status == 3%>'.
Jason Rhinelander
Gossamer Threads
jason@gossamer-threads.com
bgcolor="<%odd_color%>"
Change this to:
bgcolor="<%if post_user_is_moderator%>red<%else%><%odd_color%><%endif%>"
Obviously, change red to whatever background colour you want. If you want the changed colour for administrators' posts as well, change the '<%if ...%>' to '<%if post_user_is_moderator or user_status == 3%>'.
Jason Rhinelander
Gossamer Threads
jason@gossamer-threads.com