这是一个棘手的问题,我一直依赖于技术,比如基于许可的电子邮件(即只发送给你有权发送的人),而不是公然使用垃圾邮件术语。
最近,我以编程方式发送的一些电子邮件开始被自动转移到别人的垃圾邮件文件夹中,我不知道该怎么办。
尽管这些特定的电子邮件并不是人类会标记为垃圾邮件的,具体来说,它们是包含许可密钥的电子邮件,人们已经花了很多钱购买,所以我不认为他们会认为它们是垃圾邮件
我认为这是一个很大的话题,在这个话题上我基本上是一个无知的傻瓜。
这是一个棘手的问题,我一直依赖于技术,比如基于许可的电子邮件(即只发送给你有权发送的人),而不是公然使用垃圾邮件术语。
最近,我以编程方式发送的一些电子邮件开始被自动转移到别人的垃圾邮件文件夹中,我不知道该怎么办。
尽管这些特定的电子邮件并不是人类会标记为垃圾邮件的,具体来说,它们是包含许可密钥的电子邮件,人们已经花了很多钱购买,所以我不认为他们会认为它们是垃圾邮件
我认为这是一个很大的话题,在这个话题上我基本上是一个无知的傻瓜。
当前回答
在过去的工作中,我在很多网站上都遇到过同样的问题。确保用户收到邮件的唯一保证方法是建议用户将你添加到安全列表中。其他任何方法都只能帮助解决这个问题,而且不能保证。
其他回答
以下是之前回答中的几个要点:
Most important: Does the sender address ("From") belong to a domain that runs on the server you send the E-Mail from? If not, make it so. Never use sender addresses like xxx@gmail.com. User reply-to if you need replies to arrive at a different address. Is your server on a blacklist (e.g. check IP on spamhaus.org)? This is a possibility when you're on shared hosting when neighbours behave badly. Are mails filtered by a spam filter? Open an account with a freemailer that has a spam folder and find out. Also, try sending mail to an address without any spam filtering at all. Do you possibly need the fifth parameter "-f" of mail() to add a sender address? (See mail() command in the PHP manual) If you have access to log files, check those, of course. Do you check the "from:" address for possible bounce mails ("Returned to sender")? You can also set up a separate "errors-to" address.
您需要反向DNS条目。您不需要将相同的内容发送给同一用户两次。您需要使用一些常见的web邮箱和电子邮件客户端进行测试。 就我个人而言,我通过一个新安装的垃圾邮件杀手,一个训练有素的垃圾邮件杀手,和多个hotmail, gmail和aol帐户运行我的。
但是你有没有看到垃圾邮件似乎没有链接或广告什么?这是一个垃圾邮件发送者试图影响你的贝叶斯过滤器。如果他能得到一个很高的评价,然后在他未来的电子邮件中加入一些单词,这可能会自动学习。所以你不能真正猜测用户的过滤器会在你的邮件发送时被设置为什么。
最后,我没有按领域对列表进行排序,而是随机化了。
你能做的最重要的事情是确保你要发送电子邮件的人在收到你的电子邮件时不太可能点击“垃圾邮件”按钮。所以,请遵循以下经验法则:
Make sure you have permission from the people you are sending email to. Don't ever send email to someone who did not request it from you. Clearly identify who you are right at the top of each message, and why the person is receiving the email. At least once a month, send out a reminder email to people on your list (if you are running a list), forcing them to opt back in to the list in order to keep receiving communications from you. Yes, this will mean your list gets shorter over time, but the up-side is that the people on your list are "bought in" and will be less likely to flag your email. Keep your content highly relevant and useful. Give people an easy way to opt out of further communications. Use an email sending service like SendGrid that works hard to maintain a good IP reputation. Avoid using short links - these are often blacklisted.
遵循这些经验法则将大有裨益。
要允许DMARC检查SPF通过,并在使用sendmail时进行对齐,请确保将信封发件人地址(-f或-r参数)设置为与From:报头地址中的域匹配的内容。
PHP:
使用PHP内置的mail()函数而不设置第5个参数将导致DMARC SPF检查不对齐。默认情况下,sendmail将以web服务器的用户RFC5321发送电子邮件。MailFrom / Return路径头。
例如,假设您在host.com web服务器上托管您的网站domain.com。如果您不设置附加参数参数:
mail($to,$subject,$message,$headers); // Wrong way
电子邮件收件人将收到一封带有以下邮件标题的电子邮件:
Return-Path: <your-website-user@server.host.com>
From: <your-website-user@domain.com>
即使这通过了SPF检查,它也将是不对齐的(因为domain.com和host.com不匹配),这意味着DMARC SPF检查将失败为不对齐。
相反,你必须通过包含PHP mail()函数中的第5个参数将信封发件人地址传递给sendmail,例如:
mail($to,$subject,$message,$headers, '-r bounce_email@domain.com'); // Right way
在这种情况下,电子邮件收件人将收到一封带有以下邮件标题的电子邮件:
Return-Path: <bounce_email@domain.com>
From: <your-website-user@domain.com>
由于这两个报头都包含来自domain.com的地址,因此SPF将通过并对齐,这意味着DMARC也将通过SPF检查。
我发现,在邮件正文中使用收件人的真实姓名是通过垃圾邮件过滤器的可靠方法。