0){ // $_GET['sid']=intval($_GET['sid']); //} if(!$_GET['sid'] || intval($_GET['sid'])==0){ $pauserinfo = $DB->fetch_one_array("SELECT * FROM ".$db_prefix."sort WHERE parentid='1' ORDER BY displayorder,binary title,sortid ASC LIMIT 0,1"); if (empty($pauserinfo)) { } else { $_GET['sid']=$pauserinfo[sortid]; } }else if(intval($_GET['sid'])>0){ $_GET['sid']=intval($_GET['sid']); } //導引根目錄 $pid=substr(buildsortnavid($_GET['sid']),1,strlen(buildsortnavid($_GET['sid']))-1); $pidary=explode(",",$pid); $pcount = count($pidary); //計算文章筆數 $sortid = intval($_GET['sid']); $ssortid="WHERE sortid=".$sortid; $nav = new buildNav; $total = $DB->fetch_one_array("SELECT COUNT(*) AS count FROM ".$db_prefix."article AS article $ssortid and langeno='gb2312' and visible=1"); $nav->total_result = $total[count]; $imageid=0; $bannerid=0; $classcontent=""; $showsort=0; $parentid=-1; $title=""; //echo $pid; //取得類別相關資料 $pauserinfo = $DB->fetch_one_array("SELECT * FROM ".$db_prefix."sort WHERE sortid='".intval($_GET['sid'])."'"); if (empty($pauserinfo)) { } else { $imageid=$pauserinfo[csimg]; $bannerid=$pauserinfo[cbannerimg]; $classcontent=$pauserinfo[cnotes]; $showsort=$pauserinfo[showsortinfos]; $parentid=$pauserinfo[parentid]; } if($imageid==0 && $bannerid==0 && $classcontent==""){ //由文章內容和類別填寫的相關資料獲取Banner等資訊 if(!empty($total[count])){ $listshow=1; foreach($pidary as $k=>$v) { $pauserinfo = $DB->fetch_one_array("SELECT * FROM ".$db_prefix."sort WHERE sortid='".intval($v)."'"); if (empty($pauserinfo)) { } else { if (!empty($pauserinfo[csimg]) || !empty($pauserinfo[cbannerimg])) { $imageid=$pauserinfo[csimg]; $bannerid=$pauserinfo[cbannerimg]; } } } }else{ if(empty($classcontent) && $parentid>0){ foreach($pidary as $k=>$v) { $pauserinfo = $DB->fetch_one_array("SELECT * FROM ".$db_prefix."sort WHERE sortid='".intval($v)."'"); if (empty($pauserinfo)) { } else { if (!empty($pauserinfo[csimg]) || !empty($pauserinfo[cbannerimg])) { $imageid=$pauserinfo[csimg]; $bannerid=$pauserinfo[cbannerimg]; $classcontent=$pauserinfo[cnotes]; } } } } } } $productsorts = productsorts(); function listsort($sortid="-1"){ global $DB,$db_prefix,$productsorts; if (isset($productsorts[$sortid])) { //foreach ($productsorts[$sortid] as $key => $sort){ listsubsort(1); //} } } function listsubsort($sortid="-1"){ global $DB,$db_prefix,$productsorts,$title; if (isset($productsorts[$sortid])) { $j=0; foreach ($productsorts[$sortid] as $key => $sort){ if($j==0){ if(!$_GET['sid'] || intval($_GET['sid'])==0){ $_GET['sid'] = $sort[sortid]; }else if(intval($_GET['sid'])>0){ $_GET['sid']=intval($_GET['sid']); } } //$ctitle = new Chinese("UTF8","GB2312",$sort[title]); //$ctitle = $ctitle->ConvertIT(); //$ctitle = new Chinese("GB2312","UTF8",$ctitle); //$ctitle = $ctitle->ConvertIT(); $ctitle = htmlspecialchars(trim($sort[ctitle])); //$cl = new Chinese("UTF8","GB2312","│"); //$cl = $cl->ConvertIT(); $cl="│"; $cl = htmlspecialchars(trim($cl)); if($_GET['sid']==$sort[sortid]){ $title=$ctitle; echo ""; echo " "; echo " "; echo " "; echo "
".$cl.$ctitle."
"; }else{ echo ""; echo " ".$cl.$ctitle.""; echo ""; } $j=$j+1; } } } function buildsortnavid($sortid){ global $parentsortid; if (empty($sortid)) return; if ($sortid!=-1){ foreach ($parentsortid[$sortid] as $psid => $ssortid) { $navbitid = ",$ssortid"; $navbitid = buildsortnavid($psid).$navbitid; } } return $navbitid; } require("./incweb/cn/inc_top.inc"); ?>
 
 
  集团简介 >   
     
  fetch_one_array("SELECT * FROM ".$db_prefix."gallery WHERE id='$bannerid'"); $filename ="/upload/images/$image[filename]"; $banner_img = ""; } else { $banner_img = ""; } echo $banner_img; if (!empty($imageid)) { $image = $DB->fetch_one_array("SELECT * FROM ".$db_prefix."gallery WHERE id='$imageid'"); $filename ="/upload/images/$image[filename]"; $articlelistbit_img = ""; $articlelistbit_img .= ""; } else { $articlelistbit_img = ""; } echo $articlelistbit_img; if ($listshow==1) { $sortid = intval($_GET['sid']); $ssortid="WHERE sortid=".$sortid; $nav = new buildNav; $nav->execute("SELECT article.* FROM ".$db_prefix."article AS article $ssortid and langeno='gb2312' and visible=1 ORDER BY article.langeno,article.displayorder,article.articleid"); while ($article = $DB->fetch_array($nav->sql_result)){ echo ""; } }else{ echo ""; } ?>
 
"; echo $article[description]; echo "
"; echo $classcontent; echo "