} if (!$error_flag && $resume->size == 0 && strlen($resume->tmp_name) != 0) { $error_flag = 1; $alert[4] = "Файл не удовлетворяет условиям загрузки"; } if (!$error_flag) { user_langs::updateUserLangs($_SESSION["uid"], $user_langs); $error .= $frl->UpdateInform($uid, $resume, $del_resume, $file_error); // Доступ пользователя к функциям сайта require_once $_SERVER['DOCUMENT_ROOT'] . "/classes/registration.php"; $reg = new registration(); $reg->checkUserAccess($uid, true); $selected = $_POST['id']; require_once $_SERVER['DOCUMENT_ROOT'] . "/classes/teams.php"; //var_dump($selected); $error .= teams::teamsDelFavoritesExcept($uid, $selected); if ($file_error) { $error_flag = 1; $alert[4] = "Файл не удовлетворяет условиям загрузки"; } } if (!$error && !$error_flag) { $info = "Изменения внесены"; } break; case "main_change": $name = change_q(substr(trim($_POST['name']), 0, 21), true); $pname = change_q(substr(trim(stripslashes($_POST['pname'])), 0, 100), true); $surname = change_q(substr(trim($_POST['surname']), 0, 21), true); $email = change_q(substr(trim($_POST['email']), 0, 64), true); $oldpwd = trim($_POST['oldpwd']);
require_once ABS_PATH . "/classes/users.php"; require_once ABS_PATH . '/classes/admin_log.php'; $user_obj = new users(); $sUid = get_uid(); $user_obj->GetUserByUID($sUid); $sObjName = $user_obj->uname . ' ' . $user_obj->usurname . '[' . $user_obj->login . ']'; $sObjLink = '/users/' . $user_obj->login; $sReason = "Аккаунт удален самостоятельно"; if ($user_obj->setUserBan(get_uid(), 0, $sReason, 4, '', 1, true)) { // если удалось заблокировать аккаунт // пишем лог admin_log::addLog(admin_log::OBJ_CODE_USER, admin_log::ACT_ID_DEL_ACC, $sUid, $sUid, $sObjName, $sObjLink, 1, '', 18, $sReason); header("Location: /users/{$user}"); } break; case "delmrec": $selected = $_POST['id']; require_once $_SERVER['DOCUMENT_ROOT'] . "/classes/teams.php"; $error .= teams::teamsDelFavoritesExcept(get_uid(), $selected); } require_once $_SERVER['DOCUMENT_ROOT'] . "/classes/payed.php"; $is_pro = payed::CheckPro($_SESSION['login']); $no_banner = !!$is_pro; $header = $rpath . "header.php"; $footer = $rpath . "footer.html"; if ($css_file) { $css_file = array($css_file); } $css_file = array('settings.css', '/css/nav.css', '/css/block/b-voting/b-voting.css'); $body_class = $is_pro ? 'p-pro' : 'p-nopro'; include $rpath . $template;