douchixu3686 2013-10-04 12:20
浏览 33
已采纳

Php邮件垃圾邮件仅用于实时ID

$headers = '';
$headers .= "Content-type: text/html; charset=iso-8859-1
";
$headers .= "MIME-Version: 1.0" . "
";
$headers .= "From: $fromName <$from>" . "
";
$headers .= "Cc: " . "
";
$headers .= "Bcc: $bcc" . "
";
$headers .= "Reply-To: successive.testing@gmail.com" . "
";
$headers .= "X-Mailer: PHP/" . phpversion();
$success = mail($to, $subject, $body, $headers, '-f reply@xyz.com');

It's working fine when i am sending mail in gmail id but when try to send mail at live, yahoo id then mail going to spam. What reason may be?

  • 写回答

2条回答 默认 最新

  • dousao9569 2013-10-04 12:27
    关注

    You can try adding following

    $headers = "From: myplace@example.com
    ";
    $headers .= "Reply-To: myplace2@example.com
    ";
    $headers .= "Return-Path: myplace@example.com
    ";
    $headers .= "CC: sombodyelse@example.com
    ";
    $headers .= "BCC: hidden@example.com
    ";
    

    These links will help you
    http://wiki.apache.org/spamassassin/AvoidingFpsForSenders

    http://www.codinghorror.com/blog/2010/04/so-youd-like-to-send-some-email-through-code.html

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论
查看更多回答(1条)

报告相同问题?