![](https://img-blog.csdnimg.cn/bcc0adf73065458c9a81351e06b99954.png)
按照提示前往libcurl - Error Codes说是SSL 证书问题
![](https://img-blog.csdnimg.cn/b77cf1d0c8274a7d98e23947a6806640.png)
解决方法:
1.前往该路径
![](https://img-blog.csdnimg.cn/74ca7faee4944fac8bded45a41259d28.png)
下载https://curl.se/ca/cacert.pem 将文件里的内容全部复制下来,然后替换上图路径的/ca-bundle.crt
里面的内容保存即可
若行不通可以尝试第二种方法
2.在执行curl操作前在前面加上如下代码
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, "https://test.com/");
curl_setopt($ch, CURLOPT_HEADER, false);
//原本的代码段
// ...
// ...
// ...
curl_close($ch);