コード例 #1
0
ファイル: detail.inc.php プロジェクト: TiMoChao/xingfu
} else {
    $strTitle = $arrInfo['title'];
}
if (!empty($arrInfo['meta_Description'])) {
    $strDescription = $arrInfo['meta_Description'];
} else {
    $strDescription = $strTitle . ',' . $arrInfo['summary'];
}
if (!empty($arrInfo['meta_Keywords'])) {
    $strKeywords = $arrInfo['meta_Keywords'];
} else {
    $strKeywords = $arrInfo['title'];
}
//下五条
$strWhereNext = "where id < {$intID}";
$arrInfoListNext = $objWebInit->getInfoList($strWhereNext, ' ORDER BY topflag DESC,submit_date DESC,id DESC', 0, 1, 'id,title,submit_date,bedeck', '', false);
$strWhereNext = "where id > {$intID}";
$arrInfoListLast = $objWebInit->getInfoList($strWhereNext, ' ORDER BY topflag DESC,submit_date DESC,id DESC', 0, 1, 'id,title,submit_date,bedeck', '', false);
// 输出到模板
$arrMOutput["smarty_assign"]['arrData'] = $arrInfo;
$arrMOutput["smarty_assign"]['arrInfoListNext'] = $arrInfoListNext;
$arrMOutput["smarty_assign"]['arrInfoListLast'] = $arrInfoListLast;
$arrMOutput["smarty_assign"]['FileCallPath'] = $objWebInit->arrGPic['FileCallPath'];
$arrMOutput["smarty_assign"]['arrMType'] = $arrMType;
$arrMOutput["smarty_assign"]['arrGWeb']['css'][] = 'weixin_news02.css';
$arrMOutput['smarty_assign']['Title'] = $strTitle . ' - ' . $arrGWeb['name'];
$arrMOutput['smarty_assign']['Description'] = $strDescription . ' - ' . $arrGWeb['name'];
$arrMOutput['smarty_assign']['Keywords'] = $strKeywords . ' - ' . $arrGWeb['name'];
$arrMOutput["smarty_assign"]['MAIN'] = $arrGSmarty['main_dir'] . 'detail.html';
$objWebInit->output($arrMOutput);