当我运行我的代码时,我得到了上面的错误。按照PHPMAiler Github页面上的说明,我在composer.json中添加了" PHPMailer /phpmailer":"^6.0“,但PHPMailer似乎没有加载。我尝试使用$mail = new PHPMailer\PHPMailer\PHPMailer(true)代替$Mail = new <em
几天后,我在XAMPP中添加了电子邮件功能,我尝试使用PHPMailer函数在XAMPP中发送电子邮件,但它无法工作,2021-06-30 08:29:38 SERVER ->Fatal error: Uncaught PHPMailer\PHPMailer\Exception: SMTP Error: Could not connect to SMTP host. in Con line 2136
我正在使用下面的PHP
我正在尝试使用PHPmailer发送电子邮件,但是当我在php.ini中更改SMTP服务器时,它在phpinfo中没有更新-它仍然显示本地主机。我假设这就是我得到错误SMTP Error: Could not connect to SMTP host的原因。你能帮我找出错误和可能的原因,为什么我不能改变SMTP服务器,即使我可以改变smtp_port
我已经尝试过在邮件服务器上这样