![]() |
Need a quick snippet of code for user permissions
I'm looking to add a navbar link for only certain usergroups, basically only have the text show up if the user is in group 1, 2 or 3. Should be pretty straight forward, but I don't see any bits of code I can swipe that look familiar enough to work. :D
Any insight would be awesome - thanks! Update #1: I found this while searching around, but it's not working. Code:
<if condition="!is_member_of($bbuserinfo, 6)"> Got it to work for single usergroups using this: Code:
<if condition="$bbuserinfo['usergroupid'] == '6'"> |
Code:
<if condition="is_member_of($bbuserinfo, X) OR is_member_of($bbuserinfo, Y) OR is_member_of($bbuserinfo, Z)">Show to groups X Y and Z</if> Code:
<if condition="in_array($bbuserinfo['usergroupid'], array(X, Y, Z))">show to groups Z Y and Z</if> |
That did it - Thank you very much!
|
All times are GMT. The time now is 02:38 AM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|