news-script/checkpw.php

11 lines
304 B
PHP
Raw Normal View History

2015-07-04 04:58:36 -05:00
<?php include("dbconn.php");
if (isset($username)) {
$result = mysql_query("select password from users where userid='$username'");
if (mysql_num_rows($result)) {
$realpw = mysql_result($result, 0);
}
if ($realpw != $password) {
exit("Wrong password, please try again.");
}
}
?>