MyBB Community Forums

Full Version: Hide link to specific user groups 1.8
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Okay what I am trying to figure out is a way to hide a link just like the admin cp is hidden to users who do not have authorization to view the page. It would be for more than just the admin group. Can someone help with this?

My goal is to place it in a top bar next to my login usercp and admincp links.

Figured it out. Adding this code did the trick in my my case it was the header_welcomeblock_member template.


<if in_array($mybb->user['usergroup'], array(GROUPID1,GROUPID2)) then>
Your content such as a link.
</if>

Simply locate the user group id code. Will be the number at the end of your url when visiting, users and groups>groups>your group

Hope this helps someone else.