帝国CMS用灵动标签调用当前文章的“上一篇”和“下一篇”
代码:
[e:loop={'selfinfo',1,0,0,'id<'.$navinfor[id].'','id desc'}]
<a href="<?php echo $bqsr[titleurl];$pre='true';?>" class="prev" title="<?=$bqr[title]?>" >上一篇:<?=$bqr[title]?></a>
[/e:loop]
<?php if(empty($pre)){echo "<a class="prev">上一篇:很抱歉没有了</a>";}?>
[e:loop={'selfinfo',1,0,0,'id>'.$navinfor[id].'','id asc'}]
<a href="<?php echo $bqsr[titleurl];$next='true';?>" class="next" title="<?=$bqr[title]?>">下一篇:<?=$bqr[title]?></a>
[/e:loop]
<?php if(empty($next)){echo "<a class="next">下一篇:很抱歉没有了</a>";}?>