if (is_member_of($vbulletin->userinfo, explode(',',$vbulletin->options['gm_ugl_view_chars']))){ print_no_permission() or whatever you want to do;}