php email _POST email password _POST password mysqli new mysqli localh

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
<?php
$email=$_POST[email];
$password=$_POST[password];
$mysqli = @new mysqli('localhost', 'root', '', 'users');
if (mysqli_connect_errno()) {
echo "Подключение невозможно: ".mysqli_connect_error();
}
$result_set = $mysqli->query('SELECT * FROM login');
while ($row = $result_set->fetch_assoc()) {
print_r($row);
echo "<br />";}
' if (in_array($email, $row)) echo "Элемент найден";
else echo "Элемент не найден";'
foreach ($row as $result_set)
if ($result_set['user'] == $email)
echo "Hello" $email;
?>