diff --git a/application/config/config.php b/application/config/config.php
index 144c754e..eb0ef45a 100644
--- a/application/config/config.php
+++ b/application/config/config.php
@@ -727,6 +727,7 @@ $config['cache']['ru']['cache_path'] = 'C:\VHD\Dropbox\wwwcache\chinahighlights.
$config['cache']['it']['cache_path'] = 'C:\VHD\Dropbox\wwwcache\viaggio-in-cina.it';
$config['cache']['ch']['cache_path'] = 'D:\wwwcache\chinahighlights.com';
$config['cache']['ah']['cache_path'] = 'D:\wwwcache\asiahighlights.com';
+$config['cache']['gh']['cache_path'] = 'D:\wwwcache\globalhighlights.com';
$config['cache']['chinatravel']['cache_path'] = 'D:\wwwcache\mobile-first\chinatravel.com';
//静态文件更新接口
diff --git a/application/controllers/information.php b/application/controllers/information.php
index 80ac6ae7..c8185c5b 100644
--- a/application/controllers/information.php
+++ b/application/controllers/information.php
@@ -423,8 +423,10 @@ class Information extends CI_Controller
$this->make_www_cache_ah('mobile', $information_new, $recommand_information);
$this->make_www_cache_ah('pc', $information_new, $recommand_information);
} else if (strcasecmp($site_code, "gh") == 0 && !empty($auto_update_cache)) {
+ $recommand_information = $this->recommand_information($information);
$information_new = $this->Information_model->Detail($this->input->post('is_id'));
- $this->make_www_cache_gh($information_new);
+ $this->make_www_cache_gh('mobile', $information_new, $recommand_information);
+ $this->make_www_cache_gh('pc', $information_new, $recommand_information);
} else if (strcasecmp($site_code, "chinatravel") == 0 && !empty($auto_update_cache)) {
//chinatravel读取模板生成PC和移动优先文件
$information_new = $this->Information_model->Detail($this->input->post('is_id'));
@@ -977,40 +979,40 @@ class Information extends CI_Controller
$template_H1 = $this->load->view($template_path . '-h1', $data_H1, TRUE);
$template = str_replace('', $template_H1, $template);
- $addthis_widget = $this->load->view($template_path . '-add-this', false, true);
- $template = str_replace('', $addthis_widget, $template);
+// $addthis_widget = $this->load->view($template_path . '-add-this', false, true);
+// $template = str_replace('', $addthis_widget, $template);
- $article_structured_data_content = $this->load->view(
- $template_path . '-structured-data-article',
- array('information' => $information, 'author' => $author),
- true);
- $template = str_replace('', $article_structured_data_content, $template);
+// $article_structured_data_content = $this->load->view(
+// $template_path . '-structured-data-article',
+// array('information' => $information, 'author' => $author),
+// true);
+// $template = str_replace('', $article_structured_data_content, $template);
} else {
- $template = str_replace('', '', $template);
- $inquiry_form_template = $this->load->view($template_path . '-inquiry-form', array('meta_product_code' => $meta_product_code), true);
- $information->ic_content = str_replace('', $inquiry_form_template, $information->ic_content);
-
- $breadcrumb_content = $this->load->view($template_path . '-breadcrumb', array('breadcrumb_data' => $breadcrumb_data), true);
- $information->ic_content = str_replace('', $breadcrumb_content, $information->ic_content);
+// $template = str_replace('', '', $template);
+// $inquiry_form_template = $this->load->view($template_path . '-inquiry-form', array('meta_product_code' => $meta_product_code), true);
+// $information->ic_content = str_replace('', $inquiry_form_template, $information->ic_content);
+//
+// $breadcrumb_content = $this->load->view($template_path . '-breadcrumb', array('breadcrumb_data' => $breadcrumb_data), true);
+// $information->ic_content = str_replace('', $breadcrumb_content, $information->ic_content);
}
//信息推荐
$template_recommand = $recommand_information; //$this->recommand_information($information); 从外面传进来,pc和移动只需要查一次,减少数据库负担
- $template = str_replace('', $this->load->view($template_path . '-next', array('recommands' => $template_recommand), TRUE), $template);
+ // $template = str_replace('', $this->load->view($template_path . '-next', array('recommands' => $template_recommand), TRUE), $template);
// //广告,改叫tips,防止被插件屏蔽
if (!empty($template_recommand['Tips Right TOP'])) {
- $template = str_replace('', "
", $template);
+ // $template = str_replace('', "", $template);
}
if (!empty($template_recommand['Tips Right'])) {
- $template = str_replace('', "" . $template_recommand['Tips Right']->it_content . "
", $template);
+ // $template = str_replace('', "" . $template_recommand['Tips Right']->it_content . "
", $template);
}
//文中的信息推荐
if (strpos($information->ic_content, '') !== false) {
- $information->ic_content = str_replace('', $this->load->view($template_path . '-recommends-article', array('recommands' => $template_recommand), TRUE), $information->ic_content);
+ // $information->ic_content = str_replace('', $this->load->view($template_path . '-recommends-article', array('recommands' => $template_recommand), TRUE), $information->ic_content);
}
//文中的线路推荐
if (strpos($information->ic_content, '') !== false) {
- $information->ic_content = str_replace('', $this->load->view($template_path . '-recommends-tour', array('recommands' => $template_recommand), TRUE), $information->ic_content);
+ // $information->ic_content = str_replace('', $this->load->view($template_path . '-recommends-tour', array('recommands' => $template_recommand), TRUE), $information->ic_content);
}
//替换内容中广告
@@ -1036,32 +1038,32 @@ class Information extends CI_Controller
$meta_addon_picture_url = get_meta($information->ic_id, 'meta_addon_picture_url');
if (!empty($meta_addon_picture)) {
if (!empty($meta_addon_picture_url)) {
- $template = str_replace('', '', $template);
+ // $template = str_replace('', '', $template);
} else {
- $template = str_replace('', '
' . $template_TrainSearch . '
', $template);
+ // $template = str_replace('', '
' . $template_TrainSearch . '
', $template);
}
}
//顶部视频
- $meta_news_video = get_meta($information->ic_id, 'meta_news_video');
- $meta_video_picture = get_meta($information->ic_id, 'meta_video_picture');
- if (!empty($meta_news_video) && !empty($meta_video_picture)) {
- $template = str_replace('', '', $template);
- }
-
- if (is_file('D:/wwwroot/origin-data.chinahighlights.com/css/mobile-first.css')) {//主样式表,内联模式,优先读取本地,没有在从网络读取,为了加速
- $main_css_string = compress_css(file_get_contents('D:/wwwroot/origin-data.chinahighlights.com/css/mobile-first.css'));
+// $meta_news_video = get_meta($information->ic_id, 'meta_news_video');
+// $meta_video_picture = get_meta($information->ic_id, 'meta_video_picture');
+// if (!empty($meta_news_video) && !empty($meta_video_picture)) {
+// $template = str_replace('', '', $template);
+// }
+
+ if (is_file('D:/wwwroot/origin-www.globalhighlights.com/css/gh-global.css')) {//主样式表,内联模式,优先读取本地,没有在从网络读取,为了加速
+ $main_css_string = compress_css(file_get_contents('D:/wwwroot/origin-www.globalhighlights.com/css/gh-global.css'));
} else {
- $main_css_string = compress_css(GET_HTTP('https://proxy-data.chinahighlights.com/css/mobile-first.css'));
+ $main_css_string = compress_css(GET_HTTP('https://origin-www.globalhighlights.com/css/gh-global.css'));
}
$template = str_replace('', '', $template);
//额外样式
$meta_addon_css = get_meta($information->ic_id, 'meta_addon_css');
if (!empty($meta_addon_css)) {
- if ($meta_addon_css == 'https://proxy-data.chinahighlights.com/css/tour-detail-former.css' && is_file('D:/wwwroot/origin-data.chinahighlights.com/css/tour-detail-former.css')) {
- $meta_addon_css_string = compress_css(file_get_contents('D:/wwwroot/origin-data.chinahighlights.com/css/tour-detail-former.css'));
- } else {
+ // if ($meta_addon_css == 'https://proxy-data.chinahighlights.com/css/tour-detail-former.css' && is_file('D:/wwwroot/origin-data.chinahighlights.com/css/tour-detail-former.css')) {
+ //$meta_addon_css_string = compress_css(file_get_contents('D:/wwwroot/origin-data.chinahighlights.com/css/tour-detail-former.css'));
+ // } else {
$meta_addon_css_string = compress_css(GET_HTTP($meta_addon_css));
- }
+ // }
$template = str_replace('', '', $template);
}
//额外js
@@ -1074,12 +1076,12 @@ class Information extends CI_Controller
$template = str_replace('', $lazy_content, $template);
//替换内容中各种标签
- $tag_why_us = $this->load->view($template_path . '-why-us', false, true);
- $template = str_replace('', $tag_why_us, $template);
+ //$tag_why_us = $this->load->view($template_path . '-why-us', false, true);
+ // $template = str_replace('', $tag_why_us, $template);
//Google广告代码
//if (!empty(get_meta($information->ic_id, 'meta_google_ad_content'))) {
- $template = str_replace('', '', $template);
+ //$template = str_replace('', '', $template);
//}
//社媒分享图片
$full_ic_photo = '';
@@ -1092,8 +1094,8 @@ class Information extends CI_Controller
$template = str_replace('', '', $template);
}
//设置图片尺寸
- if (is_dir('D:/wwwroot/origin-images.chinahighlights.com') && is_dir('D:/wwwroot/origin-www.chinahighlights.com')) {
- $template = $this->html_optimize_lib->set_image_size_local($template, 'D:/wwwroot/origin-www.chinahighlights.com', 'D:/wwwroot/origin-images.chinahighlights.com');
+ if (is_dir('D:/wwwroot/origin-images.chinahighlights.com') && is_dir('D:/wwwroot/origin-www.globalhighlights.com')) {
+ $template = $this->html_optimize_lib->set_image_size_local($template, 'D:/wwwroot/origin-www.globalhighlights.com', 'D:/wwwroot/origin-images.chinahighlights.com');
} else {
$template = $this->html_optimize_lib->set_image_size($template);
}
diff --git a/application/views/bootstrap3/information_edit.php b/application/views/bootstrap3/information_edit.php
index 050bf014..53bc8d4e 100644
--- a/application/views/bootstrap3/information_edit.php
+++ b/application/views/bootstrap3/information_edit.php
@@ -2312,7 +2312,7 @@
忽略URL重复
- config->item('site_code'), array('ch', 'cht', 'gm', 'ah', 'ct','chinatravel'))) { ?>
+ config->item('site_code'), array('ch', 'cht', 'gm', 'ah', 'gh', 'ct','chinatravel'))) { ?>