I followed a youtube video on how to set up a php contact form. My page looks okay, but the emails don’t go through and my “Thank you for contacting us…” page doesn’t come up. Can anyone look at my page source and php code and fine the problem? Thanks so much in advance!
contactformprocess.php :
<?php /* Email Variables */ $emailSubject = 'contactformprocess!'; /*Make sure this matches the name of your file*/ $webMaster = '[email protected]'; /* Data Variables */ $email = $_POST['email']; $name = $_POST['name']; $comments = $_POST['comments']; $body = <<<EODName: $name
Email: $email
Comments: $comments
EOD; $headers = "From: $email\r\n"; $headers .= "Content-type: text/html\r\n"; $success = mail($webMaster, $emailSubject, $body, $headers); /* Results rendered as HTML */ $theResults = <<<EOD sent message
Thank you for your email. Chug Life Rescue will respond to your inquiry soon!
EOD;
echo "$theResults";
?>