判断为当前页的第几篇文章,并单独输出代码,可应用于第一篇文章底部广告://需要的插入...
判断为当前页的第几篇文章,并单独输出代码,可应用于第一篇文章底部广告://需要的插入...
调用某分类最新文章,pageSize是数量,mid是分类号:...
自定义分类、标签、搜索、首页等文章分页数量,修改 functions.php 文件:function themeInit($archive) { if ($archive->is('index')) { $archive->parameter->page...
自定义标签数量(就这里面的20),按照文章数量排序:...
全部标签列表,按照MID排序:<?php $this->widget('Widget_Metas_Tag_Cloud') ->to($taglist); ?><?php while($taglist->next()): ?><li><a href="<?ph...
全部文章列表,可应用于归档或网站地图,蜘蛛指引等<?php $this->widget('Widget_Contents_Post_Recent', 'pageSize=10000')->parse('<li>{year}-{month}-...
<?php $this->thePrev(); ?> <?php $this->theNext(); ?>...
根据TAG调用相关文章:<?php $this->related(5)->to($relatedPosts); ?><ul> <?php while ($relatedPosts->next()): ?> <li><a href="<?php $relatedPosts->permalink(...
自定义一下标题,以下为代码和参考案例: <?php if($this->_currentPage>1) echo '第 '.$this->_currentPage.' 页 - '; ?><?php $this->archiveTitle('...
使用这样的代码,可以自定义相关header内容: <?php if($this->is('index')): ?><?php $this->header('description=关键字。'); ?><?php else: ?><?php $this-...