帝国cms内容页上下页的链接有标签可以直接用,但如果要调用上一章的名称和下一章的名称却发现没有标签可以用,下面说下怎样用灵动标签来调用章节名。
上一章节:
[e:loop={"select * from [!db.pre!]ecms_news where id<'$navinfor[id]' and classid='$navinfor[classid]' and checked=1 order by id desc limit 1",1,24,0}]
<a href="<?=$bqsr[titleurl]?>" title="<?=$bqr[title]?>" target="_blank"><?=$bqr[title]?></a>
[/e:loop]
[e:loop={"select * from [!db.pre!]ecms_news where id<'$navinfor[id]' and classid='$navinfor[classid]' and checked=1 order by id desc limit 1",1,24,0}]
<a href="<?=$bqsr[titleurl]?>" title="<?=$bqr[title]?>" target="_blank"><?=$bqr[title]?></a>
[/e:loop]
下一章节:
[e:loop={"select * from [!db.pre!]ecms_news where id>'$navinfor[id]' and classid='$navinfor[classid]' and checked=1 order by id limit 1",1,24,0}]
<a href="<?=$bqsr[titleurl]?>" title="<?=$bqr[title]?>" target="_blank"><?=$bqr[title]?></a>
[/e:loop]
这里用了news表,要把news改成你要查询的表明,这样就把帝国模板上个章节和下个章节的文章名弄出来了。
评论(0)