The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
Hide custom fields by usergroup?
Can someone give me a hand in creating a small plugin for vB 3.8.7? I want to hide/show the custom profile fields in usercp/editprofile by usergroup.
I guess the plugin should look something like this: Code:
if (!is_member_of($vbulletin->userinfo, array(X, Y, Z))) { unset( $vbulletin->cfield['1'], $vbulletin->cfield['2'], $vbulletin->cfield['3'] ); } |
#2
|
|||
|
|||
I think I can help a little - I think you'd want:
Code:
if (!is_member_of($vbulletin->userinfo, array(X, Y, Z))) { unset( $userinfo['field1'], $userinfo['field2'], $userinfo['field3'] ); } Edit: do you mean that you don't want to show the fields if it's the profile of a user in one of those groups, or do you mean you don't want to show anyone's field1, field2, etc to someone of one of those usergroups? |
#3
|
|||
|
|||
Quote:
|
#4
|
|||
|
|||
Quote:
Edit: I haven't tried it, but hook member_profileblock_fetch_unwrapped might work for that. |
#5
|
||||
|
||||
Hey hey Kh99, will this work on V4?
I want to hide some custom profile fields from all registered users in their usercp/editprofile ... How would I do that for v4? Thanks in advance! |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|