Answer the question
In order to leave comments, you need to log in
How to fix the problem with authorization?
" https://drive.google.com/open?id=0B6L5LFWpASkCN3dI... ">
Answer the question
In order to leave comments, you need to log in
Are you seriously?
Okay, there's a wild govnokod, Okay.
Well, there are no "templates" there (that is, to change your slogan, you need to get into all the files).
But a pancake, I at first did not find authorization there.
Secondly: isn't it easier to throw a piece of Code, and not the whole project here, and clarify the error?
<?php
if (isset ($_POST['done'])) {
$login = $_POST["login"];
$password = $_POST["password"];
if(empty($login)) {
exit ("You didn't enter a login.");
}
if(empty($password)) {
exit("You didn't enter a password");
}
$password = crypt(md5($password));
$mysqli = new mysqli("localhost", "root", "", "ural_steel");
$result = $mysqli -> query("
SELECT `id`
FROM `registr`
WHERE `login`='$login'
");
$r1 = $result -> num_rows;
if ($r1 == 0) {
exit("This login does not exist!");
WHERE `login`='$login' && `password`='$password'
");
$r2 = $result2 -> num_rows;
if ($r2 == 0) {
exit("Password is wrong!");
} else {
exit ("Congratulations, you're logged in!");
}
}
}
?>
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question