PHP致命错误:phpmailerException未捕获:SMTP错误:无法验证

问题描述 投票:-3回答:1

我已经开始投票了,我是PHP的菜鸟,我了解不多。

我无法登录或经过发送到我的电子邮件的验证页链接。我已经检查了不赞成使用的文件,但显然已经进行了更改。它从来没有这样表现过,下面是我的public_html文件夹中的错误日志

Stack trace:
#0 /home2/advance2/public_html/inc/class.phpmailer.php(1542): PHPMailer->smtpConnect(Array)
#1 /home2/advance2/public_html/inc/class.phpmailer.php(1337): PHPMailer->smtpSend('Date: Mon, 25 M...', 'This is a multi...')
#2 /home2/advance2/public_html/inc/class.phpmailer.php(1215): PHPMailer->postSend()
#3 /home2/advance2/public_html/inc/regver.php(29): PHPMailer->send()
#4 {main}
  thrown in /home2/advance2/public_html/inc/class.phpmailer.php on line 1699
[25-May-2020 20:05:08 UTC] PHP Fatal error:  Uncaught phpmailerException: SMTP Error: Could not authenticate. in /home2/advance2/public_html/inc/class.phpmailer.php:1699
Stack trace:
#0 /home2/advance2/public_html/inc/class.phpmailer.php(1542): PHPMailer->smtpConnect(Array)
#1 /home2/advance2/public_html/inc/class.phpmailer.php(1337): PHPMailer->smtpSend('Date: Mon, 25 M...', 'This is a multi...')
#2 /home2/advance2/public_html/inc/class.phpmailer.php(1215): PHPMailer->postSend()
#3 /home2/advance2/public_html/inc/regver.php(29): PHPMailer->send()
#4 {main}
  thrown in /home2/advance2/public_html/inc/class.phpmailer.php on line 1699
[25-May-2020 20:05:42 UTC] PHP Deprecated:  __autoload() is deprecated, use spl_autoload_register() instead in /home2/advance2/public_html/inc/PHPMailerAutoload.php on line 45
[25-May-2020 20:05:44 UTC] PHP Fatal error:  Uncaught phpmailerException: SMTP Error: Could not authenticate. in /home2/advance2/public_html/inc/class.phpmailer.php:1699
Stack trace:
#0 /home2/advance2/public_html/inc/class.phpmailer.php(1542): PHPMailer->smtpConnect(Array)
#1 /home2/advance2/public_html/inc/class.phpmailer.php(1337): PHPMailer->smtpSend('Date: Mon, 25 M...', 'This is a multi...')
#2 /home2/advance2/public_html/inc/class.phpmailer.php(1215): PHPMailer->postSend()
#3 /home2/advance2/public_html/inc/regver.php(29): PHPMailer->send()
#4 {main}

这是class.phpmailer.php的一部分,应该有一个错误。

    }
            if ($this->SMTPAuth) {
                if (!$this->smtp->authenticate(
                    $this->Username,
                    $this->Password,
                    $this->AuthType,
                    $this->Realm,
                    $this->Workstation
                )
                ) {
                    throw new phpmailerException($this->lang('authenticate'));
                }
            }
            return true;
        } catch (phpmailerException $exc) {
            $lastexception = $exc;
            $this->edebug($exc->getMessage());
            // We must have connected, but then failed TLS or Auth, so close connection nicely
            $this->smtp->quit();
        }
    }
php
1个回答
0
投票

当SMTP验证失败时,会发生这种情况。如果已配置有效条目,请检查配置。

© www.soinside.com 2019 - 2024. All rights reserved.