The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
disable avatars for a specific user(s)
I have avatars enabled but as always there are the problem few who choose inappropriate avatars. Is there any way (short of messing with usergroups) to disable avatars for a specific user(s)? Specifically I would like a "user may not use an avatar" checkbox in their user settings so I can disable their avatars. Searched on here and vbulletin.com, found nothing
|
#2
|
|||
|
|||
Got it Took some digging and learned a few new variables along the way, but here's how to do it:
In phpinclude_start add (modify userid's as required): Code:
$banned_avatarids = array(100, 200, 300); In postbit_legacy (what I use anyway): Find Code:
<if condition="$show['avatar']"> <div class="smallfont"> <a href="member.php?$session[sessionurl]u=$post[userid]"><img src="$avatarurl" alt="<phrase 1="$post[username]">$vbphrase[xs_avatar]</phrase>" border="0" /></a> </div> </if> Add before Code:
<if condition="in_array($post[userid], $GLOBALS[banned_avatarids])"> <div class="smallfont"> Insert your text or designated avatar image here, for an image copy the href code above and modify the image source location accordingly </div> <else /> Add after Code:
</if> If you use postbit instead of postbit_legacy you'll have to compare and modify accordingly. Addendum Next is modifying the MEMBERINFO template so their avatar doesn't show in their public profile either: Find Code:
<if condition="$show['avatar']"> <td><img src="$userinfo[avatarurl]" alt="<phrase 1="$userinfo[username]">$vbphrase[xs_avatar]</phrase>" border="0" style="border:1px solid $stylevar[tborder_bgcolor]; border-top:none" /></td> <else /> <td> </td> </if> Add Before Code:
<if condition="in_array($post[userid], $GLOBALS[banned_avatarids])"> <td> Insert your text or designated avatar image here, for an image copy the img code above and modify the image source location accordingly </td> <else /> Add after Code:
</if> |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|