Greetings Everyone,
I've been having some major problems with my host today and I'm hoping for some 3rd party advice to see if they are putting me on.
I have many scripts on my site, a few of which that use the php mail() function to send a confirmation code to users in order to verify their e-mail addresses before they are allowed to be a user on my site.
All of the sudden today, my scripts stopped functioning. They will not send messages out to any e-mail address whose domain is not hosted on the same server as my site. This completely breaks all of my scripts.
My host has told me that they have prevented the server option for 'nobody' to send mails because of supposed spam reasons. They say that this is the reason the messages can’t get sent. If this is true, it seems completely illogical as it will break literally thousands of scripts, even once like phpBB which use the mail() function to send out confirmation e-mails to its users.
Does there explanation for why my mails aren't getting sent make any sense? In all of the php scripts, all of the headers (from, reply) are defined correctly so I'm not sure why it is trying to be sent as 'nobody'.
The server is running Redhat and Apache with PHP 4.3.10.
Below is a test script I created to test…it won’t work unless the $to variable is defined as an address @mydomain.com
<?php
$to = "myname@gmail.com";
$subject = "Test E-mail";
$mailheaders = "From: [email]postman@mydomain.com[/email]\n";
$mailheaders .= "Reply-To: [email]postman@mydomain.com[/email] \n\n";
$msg = "This is just a test message, please ignore";
//Send that sucker
mail($to, $subject, $msg, $mailheaders);
print("Mail sent to $to");
?>
Any help/incites you could give me would be greatly appreciated.
Thanks!
Nick