PHP mail() stopped working
DeadBattery who has been helping me suggested that I post my code for sending emails up here in case there is something wrong with it. The code used to work fine, but mid Janurary it stopped working. Thanks for taking a look guys.
PHP Code:<?php if(isset($_POST['submit'])) {
$to = "*********@worthingtonbaptistchurch.com";
$selected = $_POST['Email:'];
$subject = "Worthington Baptist Church Contact Form -- To: $selected";
$messagesubject = $_POST['messagesubject'];
$name_field = $_POST['name'];
$email_field = $_POST['email'];
$message = $_POST['message'];
$body = "To: $selected\n From: $name_field\n E-Mail: $email_field\n Subject: $messagesubject\n Message: $message";
echo "Your letter has been sent to the appropriate person. Thank You.";
mail($to, $subject, $body);
} else {
echo "Access denied.";
}
?>


LinkBack URL
About LinkBacks
Reply With Quote


