I have a script to send a customer an email. We have just noticed that the emails are only being sent to email addresses that end normally like : @gmail.com, @yahoo.com, @Hotmail.com, etc. Whenever we encounter a custom email address like **@platinumpets.com or *@landsberg.com the email address will not ever be received. I can confirm that the server is sending out the email, the user is just never receiving it. We have checked all spam folders and done various Google searches but I have not found any issues this similar to ours. Any ideas? Here is the code :
<?PHP
$subject = "Alert";
$mailheader.= "From: " . "Smartphone Pet Tag Team <[email protected]>
";
$mailheader.= "X-Sender: " . "[email protected]
";
$mailheader.= "Return-Path: " . "[email protected]
";
$mailheader .= "Bcc: [email protected]";
$body .= "Dear " . $ownername . ",
";
$body .= "" . $petname . "'s Smartphone Pet Tag has just been scanned.
";
$body .= "Click here to Login :
";
$body .= "http://www.smartphonepettag.com
";
$body .= "********************
";
// $body .= "Scan detected at " . $
//$body .= "Your pets id tag was scanned at the following date and time: " . $datetime; . ",
";
// $body .= "To stop receive automated alerts click here:
";
// $body .= 'http://www.smartphonepettag.com/id/alert.php';
// $body .= "and provide your username and password to remove these alerts.
$body .= "Regards,";
$body .= "
";
$body .= "Smartphone Pet Tag Team";
$body .= "
";
$body .= "Keeping Pets Safe and Found";
mail($email_to, $subject, $body, $mailheader ) or die ("Mail could not be sent.");
//end email alert
}
//$id=$_GET["id"];;
if (!$id) {
echo 'You have not entered an ID number. Please go back and try again.';
exit;
}
if ($id=="id=app") {
header("Location: http://www.smartphonepettag.com/id/app.php");
exit;
}
header("Location: http://www.smartphonepettag.com/id/profile.php?id=$id");
?>
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…