= 1) ? $_GET['p'] : 1; $itemPerPage = 48; $itemStart = ($page - 1) * $itemPerPage; $collMagItem = array(); $tmpMagazine = array(); if ($cat_ename == 'all') { foreach ($magCatNameAry as $k => $v) { $incfile = $MAG_DATA_DIR . $k . '.inc'; $collMagItem = LoadRequireFile($incfile); if ($collMagItem) { $tmpMagazine = array_merge($tmpMagazine, $collMagItem); } } $collMagItem = $tmpMagazine; } else { $incfile = $MAG_DATA_DIR . $cat_ename . '.inc'; $collMagItem = LoadRequireFile($incfile); $collMagItem = is_array($collMagItem) ? $collMagItem : array(); } # 總筆數 $totalNews = count($collMagItem); if($totalNews<1) { oops('000'); } # 只取需要的數量 $collMagItem = array_slice($collMagItem, $itemStart, $itemPerPage); if (!$collMagItem) { oops('000'); } # 右欄空氣品質 $rightAir = rightAir(); # 右欄氣象資訊 $rightWeather = right_get_weather(); # 右欄樂透 $rightLottery = rightLottery(); # 右欄星座 $rightConstellation = rightConstellation(); # 右欄雜誌媒體名單 $collMagMediaItem = rightCollMedia('magazine'); # 頁面資訊 $html_title = '合作媒體 - 雜誌 - PChome Online 新聞'; $html_description = $html_keywords = ''; foreach ($collMagItem as $k => $v) { if (strstr($html_description, $v['article'][0]['title'])) { continue; } $html_description .= $v['article'][0]['title'] . ', '; if (strstr($html_keywords, $v['name'])) { continue; } $html_keywords .= $v['name'] . ', '; } $html_description = substr($html_description, 0, -2); $html_keywords = substr($html_keywords, 0, -2); # 廣告 $UAD = getUserAD(90, 91, 92, 93, 94); # 時間檢測 PageLoadCostTime(); # 記憶體檢測 PageLoadCostMemory(); # PV 記錄 pv('ML'); $pv_js_code = pv_js_code('ML'); # 讀入版型 $template = $TEMPLATES . 'base_body.tpl.html'; require_once($template);