if (_rows($check)) { $sel = "selected=\"selected\""; } else { $sel = ""; } $posi .= show(_select_field_posis, array("value" => $getpos['id'], "sel" => $sel, "what" => re($getpos['position']))); } $qrysquser = db("SELECT squad FROM " . $db['squaduser'] . "\n WHERE user = '******'edit']) . "'\n AND squad = '" . $getsq['id'] . "'"); if (_rows($qrysquser)) { $check = "checked=\"checked\""; } else { $check = ""; } $esquads .= show(_checkfield_squads, array("id" => $getsq['id'], "check" => $check, "eposi" => $posi, "noposi" => _user_noposi, "squad" => re($getsq['name']))); } $show = show($dir . "/register", array("registerhead" => _useradd_head, "pname" => _loginname, "pnick" => _nick, "pemail" => _email, "pbild" => _config_c_upicsize, "ppwd" => _pwd, "squadhead" => _admin_user_squadhead, "squad" => _member_admin_squad, "posi" => _profil_position, "esquad" => $esquads, "about" => _useradd_about, "level_info" => _level_info, "rechte" => _config_positions_rights, "getpermissions" => getPermissions(), "getboardpermissions" => getBoardPermissions(), "forenrechte" => _config_positions_boardrights, "preal" => _profil_real, "psex" => _profil_sex, "sex" => _pedit_male, "pbday" => _profil_bday, "dropdown_age" => $dropdown_age, "pwohn" => _useradd_wohn, "pcity" => _profil_city, "pcountry" => _profil_country, "country" => show_countrys($get['country']), "gmaps" => $gmaps, "level" => _admin_user_level, "ruser" => _status_user, "trial" => _status_trial, "alvl" => "", "member" => _status_member, "admin" => _status_admin, "banned" => _admin_level_banned, "value" => _button_value_reg)); if ($_GET['do'] == "add") { $check_user = db("SELECT id FROM " . $db['users'] . "\n\t\t\t\t\t\t\t\t\t\t\tWHERE user = '******'user'] . "'"); $check_nick = db("SELECT id FROM " . $db['users'] . "\n\t\t\t\t\t\t\t\t\t\t\tWHERE nick = '" . $_POST['nick'] . "'"); $check_email = db("SELECT id FROM " . $db['users'] . "\n\t\t\t\t\t\t\t\t\t\t\t WHERE email = '" . $_POST['email'] . "'"); if (empty($_POST['user'])) { $show = error(_empty_user, 1); } elseif (empty($_POST['nick'])) { $show = error(_empty_nick, 1); } elseif (empty($_POST['email'])) { $show = error(_empty_email, 1); } elseif (!check_email($_POST['email'])) { $show = error(_error_invalid_email, 1); } elseif (_rows($check_user)) { $show = error(_error_user_exists, 1); } elseif (_rows($check_nick)) {
$qrysquser = db("SELECT squad FROM " . $db['squaduser'] . "\n WHERE user = '******'edit']) . "'\n AND squad = '" . $getsq['id'] . "'"); if (_rows($qrysquser)) { $check = "checked=\"checked\""; } else { $check = ""; } $esquads .= show(_checkfield_squads, array("id" => $getsq['id'], "check" => $check, "eposi" => $posi, "noposi" => _user_noposi, "squad" => re($getsq['name']))); } $get_identy = show(_admin_user_get_identitat, array("id" => $_GET['edit'])); $editpwd = show($dir . "/admin_editpwd", array("pwd" => _new_pwd, "epwd" => "")); if ($chkMe == 4) { $elevel = show(_elevel_admin_select, array("selu" => $selu, "selt" => $selt, "selm" => $selm, "sela" => $sela, "ruser" => _status_user, "banned" => _admin_level_banned, "trial" => _status_trial, "member" => _status_member, "admin" => _status_admin)); } elseif (permission("editusers")) { $elevel = show(_elevel_perm_select, array("selu" => $selu, "selt" => $selt, "selm" => $selm, "ruser" => _status_user, "banned" => _admin_level_banned, "trial" => _status_trial, "member" => _status_member)); } $index = show($dir . "/admin", array("enick" => re($get['nick']), "user" => intval($_GET['edit']), "value" => _button_value_edit, "eemail" => $get['email'], "eloginname" => $get['user'], "esquad" => $esquads, "editpwd" => $editpwd, "eposi" => $posi, "rechte" => _config_positions_rights, "getpermissions" => getPermissions(intval($_GET['edit'])), "getboardpermissions" => getBoardPermissions(intval($_GET['edit'])), "forenrechte" => _config_positions_boardrights, "showpos" => getrank($_GET['edit']), "nothing" => _nothing, "listck" => empty($get['listck']) ? '' : ' checked="checked"', "clankasse" => _user_list_ck, "auth_info" => _admin_user_clanhead_info, "alvl" => $get['level'], "elevel" => $elevel, "level_info" => _level_info, "gallery" => _admin_user_gallery, "yes" => _yes, "no" => _no, "cw_info" => _cw_info, "edithead" => _admin_user_edithead, "personalhead" => _admin_user_personalhead, "squadhead" => _admin_user_squadhead, "clanhead" => _admin_user_clanhead, "nick" => _nick, "email" => _email, "loginname" => _loginname, "identitat" => _admin_user_identitat, "get" => $get_identy, "squad" => _member_admin_squad, "newsletter" => _member_admin_newsletter, "downloads" => _member_admin_downloads, "links" => _member_admin_links, "votes" => _member_admin_votes, "votesadmin" => _member_admin_votesadmin, "gb" => _member_admin_gb, "forum" => _member_admin_forum, "intnews" => _member_admin_intnews, "intforum" => _member_admin_intforums, "i_forum" => $i_forum, "forums" => _forum, "access" => _access, "news" => _member_admin_news, "clanwars" => _member_admin_clanwars, "posi" => _profil_position, "level" => _admin_user_level, "ck" => _admin_user_clankasse, "sl" => _admin_user_serverliste, "eu" => _admin_user_edituser, "et" => _admin_user_edittactics, "esq" => _admin_user_editsquads, "eserver" => _admin_user_editserver, "ek" => _admin_user_editkalender)); } } } break; } ## SETTINGS ## $whereami = preg_replace_callback("#autor_(.*?)\$#", create_function('$id', 'return data("$id[1]","nick");'), $where); $title = $pagetitle . " - " . $whereami . ""; $time_end = generatetime(); $time = round($time_end - $time_start, 4); page($index, $title, $where, $time); ## OUTPUT BUFFER END ## gz_output(); ?>
db("INSERT INTO " . $db['f_access'] . " SET `pos` = '" . intval($_GET['id']) . "', `forum` = '" . $v . "'"); } } //////////////////// $show = info(_pos_admin_edited, "?admin=positions"); } } elseif ($_GET['do'] == "delete") { db("DELETE FROM " . $db['pos'] . " WHERE id = '" . intval($_GET['id']) . "'"); db("DELETE FROM " . $db['permissions'] . " WHERE pos = '" . intval($_GET['id']) . "'"); $show = info(_pos_admin_deleted, "?admin=positions"); } elseif ($_GET['do'] == "new") { $qry = db("SELECT * FROM " . $db['pos'] . "\n ORDER BY pid"); while ($get = _fetch($qry)) { $positions .= show(_select_field, array("value" => $get['pid'] + 1, "what" => _nach . ' ' . re($get['position']), "sel" => "")); } $show = show($dir . "/form_pos", array("newhead" => _pos_new_head, "do" => "add", "pos" => _position, "rechte" => _config_positions_rights, "getpermissions" => getPermissions(), "getboardpermissions" => getBoardPermissions(), "nothing" => "", "forenrechte" => _config_positions_boardrights, "positions" => $positions, "kat" => "", "what" => _button_value_add, "dlkat" => _admin_download_kat)); } elseif ($_GET['do'] == "add") { if (empty($_POST['kat'])) { $show = error(_pos_empty_kat, 1); } else { if ($_POST['pos'] == "1" || "2") { $sign = ">= "; } else { $sign = "> "; } $posi = db("UPDATE " . $db['pos'] . "\n SET `pid` = pid+1\n WHERE pid " . $sign . " '" . intval($_POST['pos']) . "'"); $qry = db("INSERT INTO " . $db['pos'] . "\n SET `pid` = '" . (int) $_POST['pos'] . "',\n `position` = '" . up($_POST['kat']) . "'"); $posID = mysql_insert_id(); // permissions foreach ($_POST['perm'] as $v => $k) { $p .= "`" . substr($v, 2) . "` = '" . intval($k) . "',";