connect_error){ die("Ошибка подключения". $mysql->connect_error); } session_start(); $email = $_SESSION['email']; $login = $_SESSION['login']; $pass = $_SESSION['password']; if($kod == $_SESSION['kod']) { $query = "INSERT INTO Login (`role`,`email`,`login`, `password`) VALUES (0,'$email', '$login', '$pass')"; if($result = $mysql->query($query)) { $_SESSION['login'] = $login; $_SESSION['password'] = $pass; echo ""; } } else header('Location: EmailCheck.html?message=Неверный+код'); echo ""; mysqli_close(); ?>