Beispiel #1
0
include "data/config.inc.php";
include "classes/function.viscacha_frontend.php";
$zeitmessung1 = t1();
$slog = new slog();
$my = $slog->logged();
$lang->init($my->language);
$tpl = new tpl();
$my->p = $slog->Permissions();
if ($my->p['team'] == 0) {
    errorLogin();
}
$breadcrumb->Add($lang->phrase('team'));
echo $tpl->parse("header");
echo $tpl->parse("menu");
$mymodules->load('team_top');
$team = $slog->getTeamID();
$cache = array();
$t = array_merge($team['admin'], $team['gmod']);
foreach ($t as $row) {
    $cache[] = "FIND_IN_SET({$row},groups)";
}
$result = $db->query('SELECT id, name, mail, hp, location, fullname, groups FROM ' . $db->pre . 'user WHERE ' . implode(' OR ', $cache) . ' ORDER BY name ASC', __LINE__, __FILE__);
$admin_cache = array();
$gmod_cache = array();
while ($row = $gpc->prepare($db->fetch_object($result))) {
    $gids = explode(',', $row->groups);
    foreach ($gids as $gid) {
        if (in_array($gid, $team['admin'])) {
            $admin_cache[] = $row;
        } elseif (in_array($gid, $team['gmod'])) {
            $gmod_cache[] = $row;