caching = true; $smarty->cache_lifetime = 0; $smarty->left_delimiter = "{"; $smarty->right_delimiter = "}"; $cy =(int)$_GET["cy"]; $sid =(int)$_GET["sid"]; if ( $sid ==0 || $cy ==0 ){ echo ""; die(); } if(!$smarty->isCached("newsinfo.tpl",$sid)) { require("/www/web/joy1996.com/includes_php_config/sys_function.php"); $about_query=tep_db_query("select * from html_news_list where id=" . $sid); $date_news_text = tep_db_fetch_array($about_query); $class_id = (int)$date_news_text["class_id"]; $keyword_id = $date_news_text["keyword_id"]; if ( $class_id ==0 ){ echo ""; die(); } tep_db_query("update html_news_list set click=click+1 where id=" . $sid); $check_file_query=tep_db_query("select a.id,a.t_name,a.country_id,b.t_name as cy_name,b.t_inc_file as cy_file from html_news_class a,html_country b where a.country_id=b.id and a.id=" . $class_id); $date_check_file_text = tep_db_fetch_array($check_file_query); if ( $date_check_file_text['country_id']!=$cy ){ Header("HTTP/1.1 301 Moved Permanently"); Header("Location: http://www.joy1996.com/".$date_check_file_text['cy_file']."/newsinfo-".$sid.".html"); //echo ""; //echo $date_check_file_text['country_id'] . "---" . $cy; die(); } if ($date_news_text["seo_title"]!=""){ $smarty->assign("seo_title",$date_news_text["seo_title"]); $smarty->assign("seo_keywords",''); $smarty->assign("seo_description",''); }else{ $smarty->assign("seo_title",$date_news_text["t_name"]); $smarty->assign("seo_keywords",''); $smarty->assign("seo_description",''); } $menu_country=''; $query_list=tep_db_query("select * from html_country where t_status=0 order by sort_order desc,id LIMIT 0 , 9"); while ($date_list = tep_db_fetch_array($query_list)) { if ( $date_list["id"]==886 ){ $menu_country.='
  • '.$date_list['t_url_seo'].'
  • '; }else{ $menu_country.='
  • '.$date_list['t_url_seo'].'
  • '; } } $smarty->assign("menu_country",$menu_country); $class_query=tep_db_query("select a.*,b.t_name as country_name,b.t_inc_file as country_file,b.t_url,b.t_banner,b.t_url_seo from html_news_class a,html_country b where a.country_id =b.id and a.id=" . $class_id); $date_class_text = tep_db_fetch_array($class_query); $smarty->assign("country_id",$date_class_text["country_id"]); $smarty->assign("country_name",$date_class_text["country_name"]); $smarty->assign("country_file",$date_class_text["country_file"]); $banner_pics =''.$date_class_text['t_url_seo'].''; $smarty->assign("banner_pics",$banner_pics); $daohang_links = '悦洋海外 > '.$date_class_text['t_url_seo'].' > '.$date_class_text['t_name'].' >' . $date_news_text['t_name']; $smarty->assign("daohang_links",$daohang_links); $news_info_title = $date_news_text["t_name"]; $smarty->assign("news_info_title",$news_info_title); $news_info_data_tags = '时间:'.$date_news_text['publish_date'].'      来源:'.$date_news_text['source_name'] . ''; $smarty->assign("news_info_data_tags",$news_info_data_tags); $news_info_content= tep_seo_links_keyword(stout($date_news_text["t_content"])); $smarty->assign("news_info_content",$news_info_content); $news_info_xiangguan=''; $query_xiangguan_list=tep_db_query("select * from html_news_list where publish_date <=now() and admincheck=0 and class_id='$class_id' and id!='$sid' and class_id not in (select id from html_news_class where wyid=2) order by sort_order desc,id desc LIMIT 0 , 10"); while ($date_xiangguan_list = tep_db_fetch_array($query_xiangguan_list)) { $news_info_xiangguan.= '
  • '.cutstrbylen($date_xiangguan_list['t_name'],25).'
  • '; } $smarty->assign("news_info_xiangguan",$news_info_xiangguan); $yimin_event_show=''; $query_event_list=tep_db_query("select * from html_events where events_type=1 or (events_type =0 and date(t_events_time_out)>=now()) order by events_type,sort_order desc,id desc LIMIT 0 , 2"); while ($date_event_list = tep_db_fetch_array($query_event_list)) { if ( $date_event_list['t_huigu']!="" || $date_event_list['events_type']==1){ $yimin_event_show.=' 【'.$date_event_list['t_events_city'].'】 '.$date_event_list['t_events_date'].'
    '.$date_event_list['t_name'].'
    '.$date_event_list['t_name'].' '.$date_event_list['t_name'].'
    '; }else{ $yimin_event_show.=' 【'.$date_event_list['t_events_city'].'】 '.$date_event_list['t_events_date'].'
    '.$date_event_list['t_name'].'
    '.$date_event_list['t_name'].' '.$date_event_list['t_name'].'
    '; } } $smarty->assign("yimin_event_show",$yimin_event_show); $right_last_news=''; $query_xiangguan_class_list=tep_db_query("select a.id,a.t_name,b.country_id,c.t_inc_file from html_news_list a,html_news_class b,html_country c where a.class_id=b.id and b.country_id=c.id and a.publish_date <=now() and a.admincheck=0 and a.id!='2330' and a.class_id not in (select id from html_news_class where wyid=2) order by a.sort_order desc,a.id desc LIMIT 0 , 15"); while ($date_xiangguan_class_list = tep_db_fetch_array($query_xiangguan_class_list)) { $right_last_news.= '
  • '.cutstrbylen($date_xiangguan_class_list['t_name'],20).'
  • '; } $smarty->assign("right_last_news",$right_last_news); } $smarty->display("newsinfo.tpl",$sid); ?>