ошибки Undefined

This commit is contained in:
2023-08-16 01:48:29 +03:00
parent 0f30620f61
commit 80ef052c6e
13 changed files with 1900 additions and 2205 deletions
+6 -14
View File
@@ -117,7 +117,7 @@ if (!isset($u['id'])) {
<HTML lang="ru">
<HEAD>
<link rel=stylesheet type="text/css">
<meta name="msapplication-config" content="browserconfig.xml"/>
<TITLE>Второй пароль</TITLE>
</HEAD>
@@ -300,27 +300,19 @@ if (!isset($u['id'])) {
$cmsg->setType(6);
$chat->sendMsg($cmsg);
}
$apu = "`auth` = '" . md5($u['login'] . 'AUTH' . IP) . "',";
$apu = "auth = '" . md5($u['login'] . 'AUTH' . IP) . "',";
setcookie('auth', md5($u['login'] . 'AUTH' . IP), time() + 60 * 60 * 24 * 365, '', Config::get('host'));
}
if ($u['repass'] == 0) {
$ipnew = IP;
} else {
$ipnew = $u['ip'];
}
$ipnew = IP;
Db::sql('insert into logs_auth (uid, ip, browser, time) values (?,?,?,unix_timestamp())', [
$u['id'], IP, $_SERVER['HTTP_USER_AGENT']
$u['id'], IP, $_SERVER['HTTP_USER_AGENT'],
]);
mysql_query(
"UPDATE `users` SET " . $apu . "`ip`='" . $ipnew . "',`dateEnter`='" . $_SERVER['HTTP_USER_AGENT'] .
"',`online`='" . time() . "' WHERE `id` = " . $u['id']
);
Db::sql("update users set $apu ip = ?, dateEnter = ?, online = unix_timestamp() where id = ?", [$ipnew, $_SERVER['HTTP_USER_AGENT'], $u['id']]);
$_SESSION['uid'] = $u['id'];
header('location: /bk');
exit();
}