The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
Conditional needed to hide contact info from certain usergroups on profiles
Hey gang, as the title indicates, I am looking to learn how to make it so certain usergroups do not have access to see the contact info provided in the memberinfo template. On my forums we have had rampant problems with people signing up and essentially viewing hundreds of profiles to gather contact info to then spam, usually with their forum. We used vB's promotions system for awhile now to place users into a special group that lacked profile access and private message access, but I would really like to be able to give the profile access back to everyone, as long as certain usergroups are unable to view the contact info.
So if anyone knows the conditional needed (and where to place it), it would be appreciated as my efforts have either done nothing to the access regarding that or blocked all usergroups somehow. Thanks for reading this and thanks in advance to anyone who can help. (Edit: I am aware of Kerry-Anne's hack, but for some reason that did not work for me so I am seeing if there is another alternative.) |
#2
|
|||
|
|||
What about wrapping the content in a conditional statement based on the usergroup:
Code:
<if condition="$post['usergroupid'] != 12"> <tr class="alt2"> <td height="5" nowrap="nowrap" width="50%"> <div align="left"> <a href="private.php?$session[sessionurl]do=newpm&u=$userinfo[userid]"><"> <img border="0" src="/images/buttons/sendpm.gif" align="left" width="79" height="22"></a> </td> <td height="5" nowrap="nowrap" valign="top" width="50%"> <div align="left"><if condition="$userinfo['showicq']"> $userinfo[icqicon] <a href="#" dir="ltr" onclick="imwindow('icq', '$userinfo[userid]', 500, 450); return false;">$userinfo[icq]</a> </if> </div> </tr> <tr class="alt2"> <td height="5" nowrap="nowrap" valign="top" width="50%"> <div align="left"><div class="smallfont"> <a href="sendmessage.php?$session[sessionurl]do=mailmember&u=$userinfo[userid]" rel="nofollow"> <img border="0" src="/images/buttons/email.gif" align="left" width="79" height="22"></a></p> </div></td> <td height="2" nowrap="nowrap" valign="middle" width="50%"> <div align="left"><if condition="$userinfo['showaim']"> $userinfo[aimicon] <a href="#" dir="ltr" onclick="imwindow('aim', '$userinfo[userid]', 400, 200); return false;">$userinfo[aim]</a> </if></div></td> </tr> <tr class="alt2"> <td height="5" nowrap="nowrap" valign="top" width="50%"> <div align="left"><div class="smallfont"><if condition="$show['addbuddylist']"> <a href="profile.php?$session[sessionurl]do=addlist&userlist=buddy&u=$userinfo[userid]"> <img border="0" src="/images/buttons/addbuddy.gif" width="79" height="22"></a> <else /><div class="smallfont"><a href="profile.php?$session[sessionurl]do=removelist&userlist=buddy&u=$userinfo[userid]"> <img border="0" src="/images/buttons/remove.gif" align="left" width="79" height="22"></a> </if> </div></td> <td height="5" nowrap="nowrap" valign="top" width="50%"> <div align="left"><if condition="$userinfo['showmsn']"> $userinfo[msnicon] <a href="#" dir="ltr" onclick="imwindow('msn', '$userinfo[userid]', 400, 200); return false;">$userinfo[msn]</a> </if></div></td> </tr> <tr class="alt2"> <td height="5" nowrap="nowrap" valign="top" width="50%"> <div align="left"><div class="smallfont"><if condition="$show['addignorelist']"><a href="profile.php?$session[sessionurl]do=addlist&userlist=ignore&u=$userinfo[userid]"> <img border="0" src="/images/buttons/block.gif" width="79" height="22" align="left"></a></p> <else /><div class="smallfont"><a href="profile.php?$session[sessionurl]do=removelist&userlist=ignore&u=$userinfo[userid]"> <img border="0" src="/images/buttons/addbudy.gif" width="79" align="left" height="22"></a></p> </if> </div></td> <td height="2" nowrap="nowrap" valign="middle" width="50%"> <div align="left"><if condition="$userinfo['showyahoo']"> $userinfo[yahooicon] <a href="#" dir="ltr" onclick="imwindow('yahoo', '$userinfo[userid]', 400, 200); return false;">$userinfo[yahoo]</a> </if></div></td> </tr> <else /> <tr> <td> $vbphrase[im_is_private] </td> </tr> </if> Another option would be if you don't have alot of user groups, then setting the usergroups allowed to view the information instead. Code:
<if condition="is_member_of($vbulletin->userinfo, 1, 2, 3)"> </if> |
#3
|
|||
|
|||
Thanks AntiBlank. I kind of forget how exactly I did it (I did it on Friday), but I did draw much inspiration from your post (I hadn't even though to block out the icons in the postbit) and I am hoping to turn back on the profiles for that usergroup as everything finally seems to be a go with this.
Once again, thank you. - Reid |
Thread Tools | |
Display Modes | |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|