Dune had the following modification posted in the original Thread for version 1.0, however at first glance I don't see how this will apply to the new version 1.5.
Quote:
Originally Posted by dune
We use secondary groups too, primarily.  (We leave everyone except admins in Reg users (and banned, unregistered, etc). Additional permissions are in secondary groups, so we needed this to.
Here's what you need to do:
In admin_pmall.php
Find:
Code:
// Collect Array Of Members Within Specified Usergroup
$Get_Members=$DB->query("select * from ".TABLE_PREFIX."user where usergroupid='{$_POST['to_usergroup']}' order by userid");
REPLACE WITH:
Code:
// Collect Array Of Members Within Specified Usergroup
$Get_Members=$DB->query("select * from ".TABLE_PREFIX."user where usergroupid='{$_POST['to_usergroup']}' or membergroupids REGEXP '[[:<:]]{$_POST['to_usergroup']}[[:>:]]' order by userid");
Find:
Code:
// Collect Array Of Members Within Specified Usergroup
$Get_Members=$DB->query("select * from ".TABLE_PREFIX."user where usergroupid='{$_GET['usergroup']}' order by userid");
REPLACE WITH:
Code:
// Collect Array Of Members Within Specified Usergroup
$Get_Members=$DB->query("select * from ".TABLE_PREFIX."user where usergroupid='{$_GET['usergroup']}' or membergroupids REGEXP '[[:<:]]{$_GET['usergroup']}[[:>:]]' order by userid");
This will find members who are in the specified group as EITHER their primary or as a secondary. Hope that helps. Credit for the REGEXP goes to my sysadmin Dan (the Man).
|