为什么我使用PHPMailer收到HTTP ERROR 500?

时间:2018-08-31 16:27:44

标签: php phpmailer

我正在建立一个网站,并且由于常规的PHP mail()非常糟糕且缓慢,因此我决定使用PHPMailer。我已经使用composer安装了它,但是我遇到了一个错误。我的浏览器(Google Chrome)出现错误:

“该页面无法正常工作,HTTP错误500”

从控制台日志中:

POST https://qliqdronten.nl/test/aanmelding.php 500()

标题: 要求网址:https://qliqdronten.nl/test/aanmelding.php 请求方法:POST 状态码:500 远程地址:84.244.181.151:443 推荐人政策:降级时不推荐人 enter image description here

我还尝试了托管服务提供商和hotmail的推荐设置,但是这些似乎不是问题,因为每台主机都会出现问题。

如果有人有想法,请告诉我。预先感谢。

桑德

编辑:当我不使用作曲家而仅使用文件时,它也不起作用。

 use PHPMailer\PHPMailer\PHPMailer;
        use PHPMailer\PHPMailer\Exception;

        //Now include the following following files based 
        //on the correct file path. Third file is required only if you want to enable SMTP.

        require 'PHPMailer-master/src/Exception.php';
        require 'PHPMailer-master/src/PHPMailer.php';
        require 'PHPMailer-master/src/SMTP.php';

        $mail = new PHPMailer();

0 个答案:

没有答案
相关问题