phpmailer,php,header,email发送垃圾邮件 [英] phpmailer, php, header, email goes to spam

查看:201
本文介绍了phpmailer,php,header,email发送垃圾邮件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我从系统发送电子邮件时遇到问题,问题是电子邮件被传送到Gmail / yahoo / hotmail中的垃圾邮件框。我在这里发帖,在完成我的功课后,已经验证并检查了SPF设置,反向DNS设置(指向别处,并在大约5小时前进行了更改)。 RDNS检查现在说映射是完美的。但没有运气。邮件将发送到垃圾邮件箱。可能是什么问题?



背景:我使用PHP和PHPMailer发送电子邮件。

标题从收到的垃圾邮件中收到的邮件:

 交付给:ajithsubramanian@gmail.com 
收到:10.227 .144.12与SMTP id x12cs63931wbu;
2011年5月9日星期一17:05:44 -0700(PDT)
收到:10.68.64.225与SMTP id r1mr11349194pbs.250.1304985942785;
2011年五月9日星期一17:05:42 -0700(PDT)
返回路径:< info@xpal.com>
收到:从xpal.com(208.78.241.38.svwh.net [208.78.241.38])
by mx.google.com with ESMTPS id w1si21200467pbh.199.2011.05.09.17.05.40
(version = TLSv1 / SSLv3 cipher = OTHER);
星期一,2011年五月09日17:05:41 -0700(PDT)
已收到SPF:通过(google.com:域名为info@xpal.com,指定208.78.241.38为允许发件人)client- IP = 208.78.241.38;
身份验证结果:mx.google.com; spf = pass(google.com:域名info@xpal.com指定208.78.241.38为允许发件人)smtp.mail=info@xpal.com
收件人:xpal.com(Postfix,来自userid 33)
id F31C12C30BA; 2011年5月9日星期一17:05:29 -0700(PDT)
收件人:Ajith Ravi< ajithsubramanian@gmail.com>
主题:checkarun回复您在Sindura上的xpalling
X-PHP-Originating-Script:0:phpmailer_class.php
日期:2011年5月9日星期一17:05:29 -0700
来自:XPal会员警报< info@xpal.com>
回复:Xpal会员快讯< info@xpal.com>
消息ID:< e773974b10a1d7a0e54d55f489427da1@xpal.com>
X-Priority:3
X-Mailer:PHPMailer 5.1(phpmailer.sourceforge.net)
MIME-Version:1.0
Content-Type:multipart / alternative;
boundary =b1_e773974b10a1d7a0e54d55f489427da1


解决方案

因为当您使用PHP mail()函数发送邮件时,如果您使用的是共享主机,它将显示在 Received 标题。一种方法是更改​​您要发送的标题。 本文这篇文章给出了一种绕过垃圾邮件过滤器的好方法,通过更改



为获得最佳实践,您应该使用发件人策略框架(SPF),以避免被视为垃圾邮件。

您可能也对 sendmail ,它连接到另一个电子邮件帐户(例如Gmail帐户)并发送邮件从该帐户,而不是从您的本地服务器。


I am running into a problem while sending out emails from the system and the problem is that the email gets delivered to the spam box in gmail/yahoo/hotmail. I am posting here, after doing my bit of homework, and have already validated and checked the SPF settings, Reverse DNS settings(was pointing elsewhere, and made the change this morning about 5 hours ago). The RDNS check now says the mapping is perfect. Yet no luck. Mails are going to spambox. What could be the problem?

Background : I use PHP with PHPMailer to send out emails.

The header from the mail received in the spam box :

Delivered-To: ajithsubramanian@gmail.com
Received: by 10.227.144.12 with SMTP id x12cs63931wbu;
    Mon, 9 May 2011 17:05:44 -0700 (PDT)
Received: by 10.68.64.225 with SMTP id r1mr11349194pbs.250.1304985942785;
    Mon, 09 May 2011 17:05:42 -0700 (PDT)
Return-Path: <info@xpal.com>
Received: from xpal.com (208.78.241.38.svwh.net [208.78.241.38])
    by mx.google.com with ESMTPS id w1si21200467pbh.199.2011.05.09.17.05.40
    (version=TLSv1/SSLv3 cipher=OTHER);
    Mon, 09 May 2011 17:05:41 -0700 (PDT)
Received-SPF: pass (google.com: domain of info@xpal.com designates 208.78.241.38 as permitted sender) client-ip=208.78.241.38;
Authentication-Results: mx.google.com; spf=pass (google.com: domain of info@xpal.com designates 208.78.241.38 as permitted sender) smtp.mail=info@xpal.com
Received: by xpal.com (Postfix, from userid 33)
id F31C12C30BA; Mon,  9 May 2011 17:05:29 -0700 (PDT)
To: Ajith Ravi <ajithsubramanian@gmail.com>
Subject: checkarun replied on your xpalling on Sindura
X-PHP-Originating-Script: 0:phpmailer_class.php
Date: Mon, 9 May 2011 17:05:29 -0700
From: XPal Members Alert <info@xpal.com>
Reply-to: Xpal Members Alert <info@xpal.com>
Message-ID: <e773974b10a1d7a0e54d55f489427da1@xpal.com>
X-Priority: 3
X-Mailer: PHPMailer 5.1 (phpmailer.sourceforge.net)
MIME-Version: 1.0
Content-Type: multipart/alternative;
boundary="b1_e773974b10a1d7a0e54d55f489427da1"

解决方案

This is because when you send a mail with the PHP mail() function, if you are using a shared host, it will appear in your Received header. One way is to change your headers that you are sending. This article and this article give a good way to bypass spam filters by changing headers.

For best practices, you should investigate using the Sender Policy Framework (SPF) to avoid being regarded as spam.

You might also be interested in sendmail, which connects to another email account (say, a Gmail account) and sends mail from that account, not from your local server.

这篇关于phpmailer,php,header,email发送垃圾邮件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆