Создание счёта в банке при регистрации.
This commit is contained in:
parent
6c31594e9b
commit
98f5b2d99a
@ -19,10 +19,11 @@ if ($hreject) {
|
||||
if ($check > 0) {
|
||||
$error = "В системе уже есть такие данные!";
|
||||
} else {
|
||||
db::c()->query('INSERT INTO `users` (`login`,`pass`,`email`,`borndate`,`ip`,`money`,`sid`)
|
||||
VALUES ("?s", "?s", "?s", "?s", "?s", "?s", "?s")', $login, $password, $email, $birthday, $ip, '5', session_id());
|
||||
db::c()->query('INSERT INTO `users` (`login`,`pass`,`email`,`borndate`,`ip`,`sid`)
|
||||
VALUES ("?s", "?s", "?s", "?s", "?s", "?s")', $login, $password, $email, $birthday, $ip, session_id());
|
||||
$nid = db::c()->getLastInsertId();
|
||||
db::c()->query('INSERT INTO `online` (`id`, `date`, `room`) VALUES (?i, ?i, ?i)', $nid, time(), 1);
|
||||
db::c()->query('INSERT INTO `bank` (`id`, `pass`, `cr`, `owner`) VALUES (?i, "?s", "?s", ?i)', $nid, $password, '5', $nid);
|
||||
//db::c()->query('UPDATE `users` SET `sid` = "?s" WHERE `id` = ?i', session_id(), $nid);
|
||||
setcookie(GAMEDOMAIN, $nid, time() + 3600);
|
||||
setcookie("battle", time());
|
||||
|
Loading…
Reference in New Issue
Block a user