The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
Template conditional question
I'm editing the memberinfo_block_contactinfo template.
I wanted to add a conditional based on the usergroupid of the member whose profile is being viewed, not the usergroupid of the person viewing the profile page. Is the usergroupid already available here? Or do I need to make a plugin to get it? Thanks, James |
#2
|
||||
|
||||
It's already there, the $userinfo variable contains all of the data for the user you're currently viewing the memberinfo profile for. So access the userid of the person you want like so: $userinfo['usergroupid']
This is NOT the same person as $vbulletin->userinfo['usergroupid'] (well, I suppose that it can be the same person if someone is viewing their own profile). |
#3
|
|||
|
|||
Thanks TigerC10. I don't feel so badly about getting confused on that one now.
This worked for me in the template: Code:
<if condition="is_member_of($userinfo['usergroupid'], 5, 6, 9, 11, 13, 15, 17, 21, 22, 23)"> Thanks, James |
Thread Tools | |
Display Modes | |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|