diff --git a/application/controllers/information.php b/application/controllers/information.php
index 0eb57b84..68164e02 100644
--- a/application/controllers/information.php
+++ b/application/controllers/information.php
@@ -900,16 +900,17 @@ class Information extends CI_Controller
}
}
- $data_H1['ic_title'] = $information->ic_title;
-
// 检查图片地址格式
$parsed_photo = $information->ic_photo;
$parsed_photo_url = parse_url($information->ic_photo);
- if ((!isset($parsed_photo_url['host']) || !isset($parsed_photo_url['scheme'])) && isset($parsed_photo_url['path'])) {
+ if (
+ (!isset($parsed_photo_url['host']) || !isset($parsed_photo_url['scheme'])) && isset($parsed_photo_url['path'])
+ ) {
$parsed_photo = 'https://images.chinahighlights.com' . $parsed_photo_url['path'];
}
+
+ $data_H1['ic_title'] = $information->ic_title;
$data_H1['ic_photo'] = $parsed_photo;
- // $data_H1['ic_photo'] = $information->ic_photo;
$data_H1['breadcrumb_data'] = $breadcrumb_data;
$data_H1['ads_by_google'] = $ads_by_google;
$data_H1['ic_datetime'] = $information->ic_datetime;
@@ -1844,6 +1845,22 @@ class Information extends CI_Controller
$html_path .= $html_path_ext;
create_folder_by_path(dirname($html_path));
file_put_contents($html_path, $template, LOCK_EX);
+
+ // 未勾选In Article 广告时,加入标签 ,让 ezoic 识别出该页面不展示广告。
+ $meta_google_ad_article = get_meta($information->ic_id, 'meta_google_ad_article');
+ if (empty($meta_google_ad_article) || !$meta_google_ad_article) {
+ $template = str_replace(
+ '',
+ '',
+ $template
+ );
+ } else {
+ $template = str_replace(
+ '',
+ '',
+ $template
+ );
+ }
}
public function make_www_cache_ah($device, $information, $recommand_information)
diff --git a/application/views/mobile_first/gh-pc.php b/application/views/mobile_first/gh-pc.php
index c804babd..c8f6b984 100644
--- a/application/views/mobile_first/gh-pc.php
+++ b/application/views/mobile_first/gh-pc.php
@@ -12,6 +12,7 @@
+