// не попадает внутрь этого запроса // Попытка выполнить подготовленный оператор if ($ stmt-> execute ()) {
//Send Email
$to = $email;
$subject = "Email Verification";
$message = " click this link!<a href = 'http://localhost:8080/Web_Application/verify.php?vkey=$vkey'>Register Account</a>";
$headers = "From:noreply@localhost:8080 \r\n";
$headers .= "MIME-Version: 1.0" . "\r\n";
$headers .= "Content-type:text/html:charset=UTF-8" . "\r\n";
if (mail($to,$subject,$message,$headers))
{
echo ("success");
}
else {
echo("Fail");
}
// Redirect to login page
header("location: login.php");
} else{
echo "Something went wrong. Please try again later.";
}
}