无限星辰工作室-客户无限互联网动力之源
标题:
Discuz!x3.2 启用https后uc通信失败解决一例
[打印本页]
作者:
crx349
时间:
3 天前
标题:
Discuz!x3.2 启用https后uc通信失败解决一例
老站用x3.2还是很多,今天就有客户问启用了https后uc就通信失败了,刚好解决~分享下
uc_server/model/misc.php
搜索
$port = !empty($matches['port']) ? $matches['port'] : ($matches['scheme'] == 'https' ? 443 : 80);
复制代码
下面加入
if(substr($url,0,5)=='https'){
$ch = curl_init($url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
if($post){
curl_setopt($ch, CURLOPT_POST, 1);
curl_setopt($ch, CURLOPT_POSTFIELDS, $post);
}
if($cookie){
curl_setopt($ch, CURLOPT_COOKIE, $cookie);
}
curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, FALSE);
curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, FALSE);
return curl_exec($ch);
}
复制代码
保存,更新uc缓存,解决
欢迎光临 无限星辰工作室-客户无限互联网动力之源 (https://xmspace.net/)
Powered by Discuz! X3.4