且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

PHP mail()无法发送到内部地址

更新时间:2023-11-27 14:25:58

mail()不发送邮件,它只是将内容移交给本地SMTP服务器。它不会联系收件人的服务器来传递邮件。用现实的术语来说,mail()会把您的信带到大街上,然后将其放入附近的邮箱。之后,它与邮件传递完全无关。

mail() doesn't send mail, it just hands things over to the local SMTP server. It does NOT reach out to the recipient's server to deliver the mail. In real world terms, mail() walks your letter down the street and drops it into the neighborhood mailbox. After that, it has absolutely nothing more to do with mail delivery.

检查本地SMTP服务器的日志,以了解为什么不传递本地邮件。应该有一两行说明为什么要注册。也许本地MTA(邮件传输代理,又称为本地邮件人)配置不正确。

Check your local SMTP server's logs to see why the local mails aren't being delivered. There should be a line or two saying why it's registered. Perhaps the local MTA (mail-transfer agent, aka the local "mail man") isn't configured properly.