PDA

View Full Version : is_member_of doesn't accept 1 parameter


James Birkett
06-27-2010, 09:45 AM
This could just be me... but it seems is_member_of() doesn't accept one usergroupid to compare?

I tried:

if(is_member_of($vbulletin->userinfo, 6)){

}

But this doesn't seem to work... is there an alternative to this to compare both usergroup and membergroup ids?

Lynne
06-27-2010, 02:05 PM
That should work assuming that variable is available for use at whichever hook location you are using. Did you look to find the hook in the code? And look around and see what the variables are that are being used?

James Birkett
06-27-2010, 07:31 PM
I'm using the fetch_musername hook to change the markup based on the users group (no I can't use the standard formatting because I created a gradient plug-in).

--------------- Added 1277677120 at 1277677120 ---------------

Never mind... I just stuck with the $user['displaygroupid'] variable instead.