gengxin ~

hotfix/远程访问多媒体中心
lmr@hainatravel.com 7 years ago
parent 1e51afdd6d
commit 9d5c1b497a

@ -553,6 +553,28 @@ class Information extends CI_Controller {
if (isset($information->ic_type) && $information->ic_type == 'product') {
$url = $this->config->item('site_url') . '/index.php/welcome/update_cache/?static_html_url=' . $tmp;
}
//int return direct
if ($url) {
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_NOSIGNAL,1);
curl_setopt($ch, CURLOPT_TIMEOUT, 1);
curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, 0); // 对认证证书来源的检查
curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, 0); // 从证书中检查SSL加密算法是否存在
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); //禁止直接显示获取的内容
curl_setopt($ch, CURLOPT_HEADER, 0); //不需要HEAD
//curl_setopt($ch, CURLOPT_ENCODING, 'gzip');
curl_exec($ch);
curl_close($ch);
$data[] = array('name' => 'ok', 'value' => '信息保存成功请在8秒后检查更新页面。', 'url' => $url);
//如果是外部调用就返回结果,内部就不返回了
if ($this->input->post('cache_url')) {
echo json_encode($data);
}
return $data;
}
}
break;

Loading…
Cancel
Save