|
|
@ -636,6 +636,8 @@ class Information extends CI_Controller
|
|
|
|
//非产品页面
|
|
|
|
//非产品页面
|
|
|
|
$meta_product_code = get_meta($information->ic_id, 'meta_product_code');
|
|
|
|
$meta_product_code = get_meta($information->ic_id, 'meta_product_code');
|
|
|
|
if (empty($meta_product_code)) {
|
|
|
|
if (empty($meta_product_code)) {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
$ads_by_google = !empty(get_meta($information->ic_id, 'meta_google_ad_article'));
|
|
|
|
//H1模板替换
|
|
|
|
//H1模板替换
|
|
|
|
$data_H1 = array();
|
|
|
|
$data_H1 = array();
|
|
|
|
$data_H1['infocategory'] = $this->Information_model->get_detail_by_path($information->is_path, 1); //信息所属分类,获取信息顶级节点内容
|
|
|
|
$data_H1['infocategory'] = $this->Information_model->get_detail_by_path($information->is_path, 1); //信息所属分类,获取信息顶级节点内容
|
|
|
@ -644,6 +646,7 @@ class Information extends CI_Controller
|
|
|
|
$data_H1['ic_title'] = $information->ic_title;
|
|
|
|
$data_H1['ic_title'] = $information->ic_title;
|
|
|
|
$data_H1['ic_photo'] = $information->ic_photo;
|
|
|
|
$data_H1['ic_photo'] = $information->ic_photo;
|
|
|
|
$data_H1['breadcrumb_data'] = $breadcrumb_data;
|
|
|
|
$data_H1['breadcrumb_data'] = $breadcrumb_data;
|
|
|
|
|
|
|
|
$data_H1['ads_by_google'] = $ads_by_google;
|
|
|
|
$template_H1 = $this->load->view($template_path . '-h1', $data_H1, TRUE);
|
|
|
|
$template_H1 = $this->load->view($template_path . '-h1', $data_H1, TRUE);
|
|
|
|
$template = str_replace('<!--@HEAD_1@-->', $template_H1, $template);
|
|
|
|
$template = str_replace('<!--@HEAD_1@-->', $template_H1, $template);
|
|
|
|
|
|
|
|
|
|
|
@ -734,10 +737,6 @@ class Information extends CI_Controller
|
|
|
|
//if (!empty(get_meta($information->ic_id, 'meta_google_ad_content'))) {
|
|
|
|
//if (!empty(get_meta($information->ic_id, 'meta_google_ad_content'))) {
|
|
|
|
$template = str_replace('<!--@Match-Content-GOOGLE@-->', '<script async src="https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js"></script><ins class="adsbygoogle" style="display:block" data-ad-format="autorelaxed" data-ad-client="ca-pub-4231674166786366" data-ad-slot="1447610161" data-matched-content-rows-num="2,2" data-matched-content-columns-num="1,3" data-matched-content-ui-type="image_stacked,image_stacked"></ins><script>(adsbygoogle = window.adsbygoogle || []).push({});</script>', $template);
|
|
|
|
$template = str_replace('<!--@Match-Content-GOOGLE@-->', '<script async src="https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js"></script><ins class="adsbygoogle" style="display:block" data-ad-format="autorelaxed" data-ad-client="ca-pub-4231674166786366" data-ad-slot="1447610161" data-matched-content-rows-num="2,2" data-matched-content-columns-num="1,3" data-matched-content-ui-type="image_stacked,image_stacked"></ins><script>(adsbygoogle = window.adsbygoogle || []).push({});</script>', $template);
|
|
|
|
//}
|
|
|
|
//}
|
|
|
|
if (!empty(get_meta($information->ic_id, 'meta_google_ad_article'))) {
|
|
|
|
|
|
|
|
$in_article_google = $this->load->view($template_path . '-google-ad', false, true);
|
|
|
|
|
|
|
|
$template = str_replace('<!--@IN-ARTICLE-GOOGLE@-->', $in_article_google, $template);
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
//社媒分享图片
|
|
|
|
//社媒分享图片
|
|
|
|
if (!empty($information->ic_photo)) {
|
|
|
|
if (!empty($information->ic_photo)) {
|
|
|
|
$full_ic_photo = $this->config->item('site_image_url') . $information->ic_photo;
|
|
|
|
$full_ic_photo = $this->config->item('site_image_url') . $information->ic_photo;
|
|
|
|