MyBB Central

Full Version: Code For Hiding Text From Usergroup
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hey all im working on adding a google ad for my side portal box, but i need a code or wrap to put around so that i can hide the ads from my paid subscribers, can someone please help. Thanks in advance
PHP code edits are required. It's code like this that works.

$check = array("2","3","4");
if(!in_array($check,$mybb->user['usergroup']))
return;

Line one defines the group id's.
Line two checks if it's not in the array.
Line three returns and stops code execution if they are not in the array.

Adjust accordingly.
Thank you so much labrocca. True master at mybb.