/**
  * 文章信息
  */
 private function newsinfo()
 {
     $cateinfo = $this->_getcate();
     $boname = \Common\Cls\ContentCls::getmoduletablebycid();
     $bomod = BO($boname);
     $crumbs = \Common\Cls\ContentCls::breadcrumbs();
     $this->assign('crumbs', $crumbs);
     $method = $boname . 'info';
     $news = $bomod->{$method}();
     $this->_assign($news);
     $this->display($cateinfo['newstmpl']);
 }
예제 #2
0
/**
 * 设置当前选择栏目的样式
 * @param int $id
 * @param string $cls
 */
function setcur($id, $cls = 'cur')
{
    $cid = I('get.cid');
    $crumbs = \Common\Cls\ContentCls::breadcrumbs($cid);
    foreach ($crumbs as $c) {
        if ($id == $c['id']) {
            echo $cls;
            break;
        }
    }
}