简体   繁体   English

无法在 Drupal 7 中使用 PHPmailer 发送电子邮件

[英]Unable to send an email using PHPmailer in Drupal 7

My website https://www.smcin.com/ created in drupal 7 and hosted in google cloud console.我的网站https://www.smcin.com/在 drupal 7 中创建并托管在谷歌云控制台中。 I am using PHPmailer smtp module to send email through website using port 25. But not mail has been triggered and give error我正在使用 PHPmailer smtp 模块使用端口 25 通过网站发送电子邮件。但未触发邮件并给出错误

"test e-mail has NOT been sent to xxxxxxxx@yahoo.com. You should check the logs for error messages." “测试电子邮件尚未发送到 xxxxxxxx@yahoo.com。您应该检查日志以获取错误消息。”

On logs only this message has been shown:在日志中仅显示此消息:

MESSAGE:    Error sending e-mail (from xxxxxxxx@xxxxxxx.xxx to xxxxxxxx@yahoo.com).
SEVERITY:   error.

I also tried other ports (80, 465, 2525 ) and server (gmail, my official webmail) but nothing work.我还尝试了其他端口(80、465、2525)和服务器(gmail,我的官方网络邮件)但没有任何效果。 I wasted lots of time but no solution found.我浪费了很多时间,但没有找到解决方案。

Your question is unclear as to which Google Cloud Platform service you are using.您的问题不清楚您使用的是哪个 Google Cloud Platform 服务。

Assuming that you're using Compute Engine, please see Sending email from an instance .假设您使用的是 Compute Engine,请参阅从实例发送电子邮件

NB "Port 25 is always blocked and can't be used"注意“端口 25 始终被阻止且无法使用”

You should be able to configure it to use eg 465.您应该能够将其配置为使用例如 465。

You may continue to have challenges in showing a good reputation for your instances' IP addresses.在展示实例 IP 地址的良好声誉方面,您可能会继续面临挑战。

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

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