简体   繁体   English

PHP邮件发送问题

[英]PHP mail sending problems

i was created Normal php script with headers for send the mail to my clients, my clients are have business mail account on their own domain mail account. 我创建了带有标题的标准php脚本,用于将邮件发送给我的客户,我的客户在自己的域邮件帐户上拥有商业邮件帐户。 The mail function working fine for any personal account like gmail,yahoo. 对于任何个人帐户(例如gmail,yahoo),邮件功能都可以正常工作。 But if i send the mail to any business mail account it's not going to in-box , but the mail status say successfully send. 但是,如果我将邮件发送到任何企业邮件帐户,它都不会进入收件箱,但邮件状态显示已成功发送。 i had checked my mail function headers it's also looking fine. 我检查了我的邮件功能标头,它也看起来不错。 and also i had tried another php mail function like PHP-Mailer, RMail , These third-party function also return value true, but mail was not in inbox. 而且我还尝试了另一个PHP邮件功能,例如PHP-Mailer,RMail,这些第三方功能也返回值true,但是邮件不在收件箱中。 my server os in Linux, please clear this any one, thanks advance 我的服务器操作系统是Linux,请清除任何一个,谢谢

Your mailfunction will return successfully sent whenever the mail has successfully left the server. 只要邮件成功离开服务器,您的邮件功能就会成功返回。 whether the server of the recipient picks up the email, and accepts it, is unknown to your mailfunction, and totally out of your hands. 您的邮件功能未知收件人的服务器是否接收并接受电子邮件,这完全是您无法控制的。 Since you mention that your testmails being sent to your personal emailaddresses all arrive, I assume that the problem is not in your PHP program, but in the recipients mailserver not accepting the email. 由于您提到发送到个人电子邮件地址的测试邮件全部到达,因此我认为问题不在您的PHP程序中,而是在收件人邮件服务器中不接受该电子邮件。 Most probably they are being filtered as spam. 它们很可能被过滤为垃圾邮件。 A good way to prevent this is by using a real emailaddress on a valid domain and an SMTP server on that domain (same IP-Address) to send the mail from. 防止这种情况的一种好方法是在有效域上使用真实的电子邮件地址,并在该域上使用SMTP服务器(相同的IP地址)发送邮件。 Otherwise, many mailservers will see that the IP-address from the program sending the mail, and the IP-address of the mailserver in the "FROM" field are not the same, and label it as spam. 否则,许多邮件服务器会发现发送邮件的程序中的IP地址与“ FROM”字段中邮件服务器的IP地址不同,并将其标记为垃圾邮件。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM