This is my code but on clicking Login
button it shows error like this
Connection MaintainedError: select * from signup where username='abc' and password='1234'
if(isset($_POST['log'])){
$uname = $_POST['uname'];
$pass = $_POST['pass'];
$dbm = new MySQLi("localhost","root","","lsa");
if($dbm->connect_errno > 0){
die("Error".$dbm->connect_error);
}
var_dump($dbm);
echo "Connection Maintained";
$up = "update signup set username = concat(First_name, ' ' , Last_Name)";
$qm="select * from signup where username='$uname' and password='$pass'";
if ($dbm->query($qm) === TRUE) {
echo "New record created successfully";
} else {
echo "Error: " . $qm . "<br>" . $dbm->error;
}
$dbm->close();
here is my login form code*
<form action="Admin.php" method="post">
<fieldset style="text-align:center; margin-left:2%; margin-top:9%; margin-right:10%">
<legend style="text-align:start; font-family:'Palatino Linotype', 'Book Antiqua', Palatino, serif; color:#FFF; font-size:36px">Login
</legend>
<br /><input type="text" placeholder=" Username" name="uname" title="Your First Name" style="height:25px; width:200px" required="required" /><br /><br />
<input type="password" placeholder=" Password" name="pass" style="height:25px; width:200px" required="required" /><br /><br />
<input type="submit" value="Login" name="log" style=" border-radius:50%; border-color:#FFF; width:100px" />
<br />
<br />
</fieldset>
</form>