I'm learning how to send email from PHP and would like your help. I haven't received any messages from the test code below:
[php]$to = 'firstname.lastname@example.org';
$from = 'email@example.com';
$subject = 'Test';
$message = 'It works!';
$headers = "From: $from\r\n";
$headers .= "Reply-To: $from\r\n";
$headers .= "X-Mailer: PHP/".phpversion();
mail( $to, $subject, $message, $headers );
I gather from other posts that the "from" address must be a DreamHost-hosted domain, and it is.
What am I missing?