Yet another mail() question
Posted: Tue Jan 13, 2009 9:15 am
Sorry to post yet another question, I have hunted this forum but couldn't find an answer.
I have been doing some testing with a very simple mail script.
I always get "Success" when I run the script. When I'm using my googlemail email account as the to the email arrives almost instantly. When I change over to my hotmail account as the to the email never arrives, not even in spam. Anyone got any idea why?
I have been doing some testing with a very simple mail script.
Code: Select all
<?php
$to = "myemail@hotmail.com";
//$to = "myemail@googlemail.com";
$subject = "My subject";
$txt = "Hello!";
$headers = "From: noreply@pact-oil.co.uk\r\n";
if (mail($to,$subject,$txt,$headers)) {
echo "Success";
} else {
echo "Failed";
}
?>