帝国CMS动态页静态页实现上一篇 下一篇灵动标签调用方案整理

模板变量上一篇:[!--info.pre--]下一篇:[!--info.next--] 缺点:[!--info.pre--] 和 [!--info.next--] 中封装的 标签的内容无法定制灵动标签+SQL语句(亲测不可用)[e:loop={"selec

模板变量

上一篇:[!--info.pre--]
下一篇:[!--info.next--]
 

缺点:[!--info.pre--][!--info.next--] 中封装的 标签的内容无法定制I4AECMSPLUS

灵动标签+SQL语句

(亲测不可用)
[e:loop={"select * from [!db.pre!]ecms_news where id<'$navinfor[id]' and classid='$navinfor[classid]' order by id desc limit 1",1,24,0}]
上一篇:<a href="<?=$bqsr[titleurl]?>" title="上一篇:<?=$bqr[title]?>" target="_blank">&nbsp; </a>
[/e:loop]

[e:loop={"select * from [!db.pre!]ecms_news where id>'$navinfor[id]' and classid='$navinfor[classid]' order by id limit 1",1,24,0}]
下一篇:<a href="<?=$bqsr[titleurl]?>" title="下一篇<?=$bqr[title]?>" target="_blank"></a>
[/e:loop]
 

纯灵动标签

(亲测可用,2018年11月16日)
[e:loop={'selfinfo',1,0,0,'id<'.$navinfor[id].'','id desc'}]
<a href="<?php 
echo $bqsr[titleurl];
$pre='true';
?>">上一篇:<?=$bqr[title]?>
</a>
[/e:loop]
<?php 
if(empty($pre)){
echo "上一篇:很抱歉没有了";
}
?>
 
[e:loop={'selfinfo',1,0,0,'id>'.$navinfor[id].'','id asc'}]
<a href="<?php 
echo $bqsr[titleurl];
$next='true';
?>">下一篇:<?=$bqr[title]?>
</a>
[/e:loop]
<?php 
if(empty($next)){
echo "下一篇:很抱歉没有了";
}
?>
 

动态调用

<a href="/e/public/GotoNext?classid=[!--self.classid--]&id=[!--id--]&enews=pre">上一篇文章</a>
<a href="/e/public/GotoNext?classid=[!--self.classid--]&id=[!--id--]&enews=next">下一篇文章</a>
 

分享到 :
相关推荐

发表评论

登录... 后才能评论

评论(3)

加入本站VIP会员订阅计划,海量资源免费下载查看

目前为止共有3位优秀的VIP会员加入!

立即加入VIP会员