gengxin ~

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

@ -554,8 +554,9 @@ class Information extends CI_Controller {
$url = $this->config->item('site_url') . '/index.php/welcome/update_cache/?static_html_url=' . $tmp; $url = $this->config->item('site_url') . '/index.php/welcome/update_cache/?static_html_url=' . $tmp;
} }
//int return direct //int return direct
$cache_url = $this->input->post('cache_url');
if ($url) { if ($url && !$cache_url) {
ignore_user_abort(true);
$ch = curl_init(); $ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $url); curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_NOSIGNAL,1); curl_setopt($ch, CURLOPT_NOSIGNAL,1);
@ -569,7 +570,7 @@ class Information extends CI_Controller {
curl_close($ch); curl_close($ch);
$data[] = array('name' => 'ok', 'value' => '信息保存成功请在8秒后检查更新页面。', 'url' => $url); $data[] = array('name' => 'ok', 'value' => '信息保存成功请在8秒后检查更新页面。', 'url' => $url);
//如果是外部调用就返回结果,内部就不返回了 //如果是外部调用就返回结果,内部就不返回了
if ($this->input->post('cache_url')) { if ($cache_url) {
echo json_encode($data); echo json_encode($data);
} }
return $data; return $data;

Loading…
Cancel
Save