고객에게 전자 메일을 보내는 스크립트가 있습니다. 우리는 이메일이 정상적으로 끝나는 이메일 주소 (예 : @ gmail.com, @ yahoo.com, @ Hotmail.com 등)로만 전송된다는 사실을 알게되었습니다. ** @platinumpets와 같은 맞춤 이메일 주소가 발생할 때마다 .com 또는 * @ landsberg.com 이메일 주소는 수신되지 않습니다. 나는 서버가 이메일을 보내고 있다는 것을 확인할 수 있으며, 사용자는 이메일을받지 못한다. Google은 모든 스팸 폴더를 확인하고 다양한 Google 검색을 수행했지만 Google과 비슷한 문제는 발견하지 못했습니다. 어떤 아이디어? 여기에 코드입니다 :PHP 전자 메일은 사용자 정의 전자 메일 주소로 보내지 않습니다.
<?PHP
$subject = "Alert";
$mailheader.= "From: " . "Smartphone Pet Tag Team <[email protected]>\n";
$mailheader.= "X-Sender: " . "[email protected]\n";
$mailheader.= "Return-Path: " . "[email protected]\n";
$mailheader .= "Bcc: [email protected]";
$body .= "Dear " . $ownername . ", \n\n";
$body .= "" . $petname . "'s Smartphone Pet Tag has just been scanned.\n\n";
$body .= "Click here to Login :\n";
$body .= "http://www.smartphonepettag.com\n";
$body .= "********************\n\n";
// $body .= "Scan detected at " . $
//$body .= "Your pets id tag was scanned at the following date and time: " . $datetime; . ", \n";
// $body .= "To stop receive automated alerts click here: \n";
// $body .= 'http://www.smartphonepettag.com/id/alert.php';
// $body .= "and provide your username and password to remove these alerts.
$body .= "Regards,";
$body .= " \n\n";
$body .= "Smartphone Pet Tag Team";
$body .= " \n\n";
$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");
?>
'mail()'의 반환 값 및/또는 메일 서버의 로그를 검사하는 것과 같은 기본적인 디버깅을 수행하여 PHP가 전자 메일을 전달한 후에 어떤 일이 발생하는지 확인합니다. –
그는 서버가 메일을 발송하고 있음을 확인했다. 내 생각 엔 스팸 필터에 의해 차단되고있는 것 같습니다. – Barmar
미안하지만 사람들이 내 질문에 투표하는 이유는 무엇입니까? – DolbyOver