在 Ubuntu 服务器上使用 PHP 通过 SMTP 发送电子邮件

在 Ubuntu 服务器上使用 PHP 通过 SMTP 发送电子邮件

我在使用 CodeIgniter 框架编码的 PHP 应用程序发送电子邮件时遇到问题。我在 VMWare 上全新安装了 Ubuntu Server,其中安装了 Apache、PHP 和 MySQL。我收到以下错误:

220 linux11.dns-servicios.com ESMTP

hello: 250-linux11.dns-servicios.com Hello a.b.c.kion.es [83.49.x.y]
250-SIZE 31457280
250-PIPELINING
250-AUTH PLAIN LOGIN
250-STARTTLS
250 HELP

from: 250 OK

to: 550-Verification failed for 
550-mensaje de error"
550 Sender verify failed

The following SMTP error was encountered: 550-Verification failed for 550-mensaje de error" 550 Sender verify failed

data: 503-All RCPT commands were rejected with this error:
503-Sender verify failed
503 Valid RCPT command must precede DATA

The following SMTP error was encountered: 503-All RCPT commands were rejected with this error: 503-Sender verify failed 503 Valid RCPT command must precede DATA
500 unrecognized command
The following SMTP error was encountered: 500 unrecognized command
Unable to send email using PHP SMTP. Your server might not be configured to send mail using this method.

我能做些什么?

先感谢您!!!

答案1

错误在于代码,而不是服务器。

to: 550-Verification failed for 
550-mensaje de error"
550 Sender verify failed

看起来您正在将“收件人”设置为“错误信息”,显然这不是电子邮件地址。

答案2

您可以使用 google 轻松解决此问题。错误显示如下:

550 Sender verify failed

相关内容