vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=111)
-   -   Secondary Usergroup (https://vborg.vbsupport.ru/showthread.php?t=123684)

jgommel 08-11-2006 05:00 PM

Secondary Usergroup
 
Okay the code pasted below is in my NAVBAR. Basically I created a drop down menu which contains all my Admin functions - including Admin CP's for other addons etc...

What it does right now is display in the NAVBAR only for users that belong to the Admin USERGROUP (6). It appears that it's only looking for USERGROUP (6) from the Primary Usergroup field and not the Additional (Secondary) Usergroup field.

How can I alter this code to also look for Admin USERGROUP (6) if a users Additional Usergroup field is set to Admin?

Note: This question doesn't only apply to the Admin USERGROUP (6). I'll use this code for other instances. Example: User one's Primary Usergroup is Team Member and User two's Secondary Usergroup is Team Member. I want both users to have access to a certain area of the site w/out having to create a compeltly seperate USERGROUP and assigning both of the users to that new USERGROUP as their primary.

<!-- ADMIN TOOLS -->
<if condition="in_array($bbuserinfo['usergroupid'], array(6))">
<if condition="$show['admincplink']">
<if condition="$show['popups']">
<!-- start vBMenu control element -->
<td width="67" height="29" id="AdminTools"><a href="$vbphrase[admintools]#"><img id="nav_menu" src="$stylevar[imgdir_misc]/nav_admin.gif" width="67" height="29" border="0" alt="" /></a><script type="text/javascript">
vbmenu_register("AdminTools", 1);</script></td>
<!-- end vBMenu control element -->
</if>
</if>
</if>


All times are GMT. The time now is 07:55 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
  • Page Generation 0.00996 seconds
  • Memory Usage 1,704KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (1)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete