Hello,
I have a contact page on my website… Everytime I test it it doesn’t get delivered and I end up with:
said: 550 5.7.1 Sender domain not allowed. Please read:
http://dhurl.org/20b D21 (in reply to end of DATA command)
listed in my log file. I’ve read the wiki link but I still am at a loss as to what’s wrong. I’m using an e-mail in that domain hosted by dreamhost. This is my send script:
[code]<?php
// Check for empty fields
if(empty($_POST[‘name’]) ||
empty($_POST[‘email’]) ||
empty($_POST[‘phone’]) ||
empty($_POST[‘message’]) ||
!filter_var($_POST[‘email’],FILTER_VALIDATE_EMAIL))
{
echo “No arguments Provided!”;
return false;
}
$name = $_POST[‘name’];
$email_address = $_POST[‘email’];
$phone = $_POST[‘phone’];
$message = $_POST[‘message’];
// Create the email and send the message
$to = ‘chris@cjs-design.com’;
$email_subject = “Website Contact Form: $name”;
$email_body = “You have received a new message from your website contact form.\n\n”.“Here are the details:\n\nName: $name\n\nEmail: $email_address\n\nPhone: $phone\n\nMessage:\n$message”;
$headers = “From: chris@cjs-design.com”;
$headers .= “Reply-To: $email_address”;
mail($to,$email_subject,$email_body,$headers);
return true;
?>[/code]
What am I doing wrong?
Thanks in advance,
Chris