The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
Highlighting Threads by Author's User Group
I want my thread list in each sub-forum to emphasize threads that were created by Administrators. For instance, have their name in red.
It would make sense to edit the memberaction_dropdown template because this is where the user names are printed, but I can't figure out what conditional statement to write. Any suggestions? I already have the posts within a single thread doing custom styling on the username, but this doesn't affect the list of thread in a forum. |
#2
|
||||
|
||||
Try a condition like (not exactly like this since I put a comment in it!):
HTML Code:
<vb:if condition="is_member_of($memberinfo, x)"> <span style="whatever">{vb:raw memberinfo.username} (or {vb:raw memberinfo.musername} ) </span> <vb:else /> {vb:raw memberinfo.username} (or {vb:raw memberinfo.musername} ) </vb:if> |
#3
|
|||
|
|||
Hi Lynne,
I'm afraid that your suggestion didn't work. No matter what number I substitute for X, it never executes as "true". I suspect that the $member variable doesn't evaluate. Any other suggestions? |
#4
|
||||
|
||||
Whoops, sorry, it is $memberinfo. And, I didn't do the else correctly (why did I write another if???).
A correct example for replacing the username (need to do the same for musername): HTML Code:
<vb:if condition="is_member_of($memberinfo, 6)"> <span style="color:red">{vb:raw memberinfo.username}</span> <vb:else /> {vb:raw memberinfo.username} </vb:if> |
#5
|
|||
|
|||
It works!
Thank you very much! |
#6
|
|||
|
|||
Hi, now i think its not woriking ...
|
#7
|
|||
|
|||
Please describe what is not working and where you are trying to implement @Lynnes code. We can only be as helpful as per the data you provide us. Most likely you are implementing @Lynne's code snippet incorrectly. Give your question another go.
|
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|