修改栏目导航为新闻分类

This commit is contained in:
wlx 2012-04-12 04:06:58 +00:00
parent 3fc04622ff
commit 53701656e8
3 changed files with 7 additions and 26 deletions

View File

@ -1,20 +1,4 @@
<?php <?php
/*
新闻控制器路由规则:
routes.news.route = news/:type/:page
routes.news.defaults.controller = news
routes.news.defaults.action = list
routes.news.defaults.page = 1
routes.archive.type = "Zend_Controller_Router_Route_Regex"
routes.archive.route = "news/:type/archive-(\d+).html"
routes.archive.defaults.controller = news
routes.archive.defaults.action = archive
routes.archive.map.1 = "aid"
*/
class NewsController extends Zend_Controller_Action class NewsController extends Zend_Controller_Action
{ {
private $limit=10; private $limit=10;
@ -148,5 +132,4 @@ class NewsController extends Zend_Controller_Action
} }
} }

View File

@ -1,18 +1,17 @@
<?php <?php
$config = Zend_Registry::get('config'); $this->headTitle($this->config->title->site);
$this->headTitle($config->title->site); $this->headTitle('新闻中心');
$this->headTitle('News');
$this->headTitle()->setSeparator(' - '); $this->headTitle()->setSeparator(' - ');
$this->headLink()->appendStylesheet('/css/news.css'); $this->headLink()->appendStylesheet('/css/news.css');
$this->headScript()->appendFile('/js/jquery-1.7.min.js'); $this->headScript()->appendFile('/js/jquery-1.7.min.js');
$this->breadcrumb('<a href="/"></a>'); $this->breadcrumb('<a href="/"></a>');
$this->breadcrumb('新闻中心'); $this->breadcrumb('新闻中心');
$this->breadcrumb()->setSeparator(' > '); $this->breadcrumb()->setSeparator(' > ');
?> ?>
<div class="full center clear" id="body"> <div class="full center clear" id="body">
<div class="w300 Lfloat clear"> <div class="w300 Lfloat clear">
<div class="tbox"> <div class="tbox">
<div class="title">栏目导航</div> <div class="title">新闻分类</div>
<div class="content navmenu"> <div class="content navmenu">
<ul> <ul>
<?php <?php

View File

@ -1,6 +1,5 @@
<?php <?php
$config = Zend_Registry::get('config'); $this->headTitle($this->config->title->site);
$this->headTitle($config->title->site);
$this->headTitle('新闻中心'); $this->headTitle('新闻中心');
$this->headTitle()->setSeparator(' - '); $this->headTitle()->setSeparator(' - ');
$this->headLink()->appendStylesheet('/css/news.css'); $this->headLink()->appendStylesheet('/css/news.css');
@ -13,7 +12,7 @@ $this->breadcrumb()->setSeparator(' > ');
<div class="full center clear" id="body"> <div class="full center clear" id="body">
<div class="w300 Lfloat clear"> <div class="w300 Lfloat clear">
<div class="tbox"> <div class="tbox">
<div class="title">栏目导航</div> <div class="title">新闻分类</div>
<div class="content navmenu"> <div class="content navmenu">
<ul> <ul>
<?php <?php