<!
DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Registration</title>
</head>
<body>
<form action="" method="post">
First name: <input type="text" name="f_name"> Last name: <input type="text"
name="l_name"> Email: <input type="email" name="email"> Password <input
type="password" name="password">
<button type="submit" name="submit">submit</button>
</form>
<?php
if(isset($_POST['submit'])){
$f_name=$_POST['f_name'];
$l_name=$_POST['l_name'];
$email=$_POST['email'];
$password=$_POST['password'];
$con= mysqli_connect('localhost','root','','Registration');
$q="INSERT INTO cliant(f_name,l_name,email,password)
VALUES('$f_name','$l_name','$email','$password')";
if(mysqli_query($con,$q)){
echo "registration success";
}
else{
echo "error";
}
}
?>
</body>
</html>