在客户成功输入联系信息后,我正尝试将他们重定向回我的原始主页。我将如何使用以下 PHP 表单来做到这一点?提前感谢您的所有帮助!
<?php
// Receive form's subject value into php $subject variable
$subject =$_REQUEST['subject'];
// Receive form's message value into php $message variable
$message=$_REQUEST['message'];
// Receive form's sender name value into php $sender variable
$sender=$_REQUEST['name'];
// Receive form's user email value into php $user_email variable
$user_email=$_REQUEST['email'];
// the email address where the message will be sent
$TO ="ttdthemes@gmail.com";
$send_email=mail($TO,$subject,$message,"From: ".$sender."<".$user_email.">");
// To check email has been sent or not
if($send_email)
{
echo "Your E-mail has been sent !";
}
else
{
echo "E-mail sent was failed !";
}
?>