In the Memberlist.php file on line 355 here is the following code:
// check permission to do authorizations in this group
if (!$leadergroup = $db->query_first_slave("
SELECT usergroupleader.usergroupleaderid, usergroup.title
FROM " . TABLE_PREFIX . "usergroupleader AS usergroupleader
LEFT JOIN " . TABLE_PREFIX . "usergroup AS usergroup ON (usergroupleader.usergroupid = usergroup.usergroupid)
WHERE usergroupleader.userid = " . $vbulletin->userinfo['userid'] . "
AND usergroupleader.usergroupid = $usergroupid
"))
{
print_no_permission();
}
This prevents anyone from seeing the list of members for the usergroup to include admin and a user of the group unless you are the usergroup leader.
So how can I add to this if statement to bypass the admins usergroupid of 6 and a usergroup member with the membergroupids of the usergroup tied to this request.
In simplier words, I want to filter the usergroup leader, site admins, and members of the usergroup (who should be able to see it to begin with).
Code please as this would help.
Thanks.
Viper
// check permission to do authorizations in this group
if (!$leadergroup = $db->query_first_slave("
SELECT usergroupleader.usergroupleaderid, usergroup.title
FROM " . TABLE_PREFIX . "usergroupleader AS usergroupleader
LEFT JOIN " . TABLE_PREFIX . "usergroup AS usergroup ON (usergroupleader.usergroupid = usergroup.usergroupid)
WHERE usergroupleader.userid = " . $vbulletin->userinfo['userid'] . "
AND usergroupleader.usergroupid = $usergroupid
"))
{
print_no_permission();
}
This prevents anyone from seeing the list of members for the usergroup to include admin and a user of the group unless you are the usergroup leader.
So how can I add to this if statement to bypass the admins usergroupid of 6 and a usergroup member with the membergroupids of the usergroup tied to this request.
In simplier words, I want to filter the usergroup leader, site admins, and members of the usergroup (who should be able to see it to begin with).
Code please as this would help.
Thanks.
Viper
Comment