PHP的邮件如何工作? [英] How does PHP's `mail` work?
本文介绍了PHP的邮件如何工作?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
邮件函数似乎在干净的系统上传递邮件,管理员或网站管理员没有明确的配置(在 php中没有SMTP配置) .ini
等)。 mail
函数如何将邮件传递给远程服务器?解决方案在* nix上,它调用 sendmail
二进制文件,然后使用邮件配置来路由邮件。在Windows上,它发送到SMTP服务器。在这两种情况下,sysadmin设置邮件系统。
PHP's mail
function seems to deliver mail on a clean system, with no apparent configuration done by the administrator or webmaster (no SMTP configuration in php.ini
, etc.). How does the mail
function deliver mail to a remote server?
解决方案 On *nix it invokes the sendmail
binary, which then uses the mail configuration to route the email. On Windows, it sends to a SMTP server. In both cases the sysadmin sets up the mail system.
这篇关于PHP的邮件如何工作?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文