Drupal 7 开发内部培训资料, 分头诗人

Drupal邮件无法发送

赞成!
0
否决!

各位大虾, 小弟的Drupal系统无法发送邮件(前几天还好好的), 现又装上Phpmailer, 但经测试还是无法发送邮件;

检查了N遍, Phpmailer设置也没有问题..

提示是: 无法发送电子邮件。如果问题依然存在,请联系网站管理员。

求助..

2 个回答

赞成!
0
否决!

问题解决了, 跟大家分享一下;

本地测试没问题, 放到godaddy就发不出邮件, 于是咨询godaddy, 得到回复如下:

Thank you for contacting Online Support. if the Drupal is using its own email server to send out emails, it will not work. You will have to use our relay server information which should allow it to send. This relay server also allows 1000 emails per day to be sent out.

If you use the mail() function in your PHP, you do not need to specify an outgoing mail server. If you are using some other method besides mail() in your PHP code, use relay-hosting.secureserver.net for your relay server.

NOTE: A maximum of 1000 emails per day are allowed through our relay servers.

 

所以把SMTP服务器直接写成relay-hosting.secureserver.net, 不需要填写任何用户名和密码, 测试居然OK了..

赞成!
0
否决!

SMTP需要配置,举例,如果你绑定的是163免费企业邮箱,那smtp 是填smtp.ym.163.com,也可以在godaddy上面设置一个转向

smtp cname smtp.ym.163.com

然后 smtp是这样设置