帝国CMS灵动标签随机调取文章
时间:10-27
作者:
中间的部分换成你自己网站的模板代码就行了
[e:loop={"select * from {$dbtbpre}ecms_sitenav order by rand() desc limit 6",20,24,0}]
<div class="col-12 col-md-6 col-
[e:loop={"select * from {$dbtbpre}ecms_sitenav order by rand() desc limit 6",20,24,0}]
<div class="col-12 col-md-6 col-
中间的部分换成你自己网站的模板代码就行了
[e:loop={"select * from {$dbtbpre}ecms_sitenav order by rand() desc limit 6",20,24,0}]
<div class="col-12 col-md-6 col-lg-4">
<div class="ho-hotsitenav">
<em><a href="<?=$bqsr['titleurl']?>" rel="nofollow"><img src="<?=$bqr[titlepic]?>" class="img-fluid" alt="<?=$bqr['title']?>"></a></em>
<span>
<strong><a href="<?=$bqsr['titleurl']?>" rel="nofollow"><?=$bqr['title']?></a></strong>
<p><?=$bqr['smalltext']?></p>
</span>
</div>
</div>
[/e:loop]
[e:loop={"select * from {$dbtbpre}ecms_sitenav order by rand() desc limit 6",20,24,0}]
<div class="col-12 col-md-6 col-lg-4">
<div class="ho-hotsitenav">
<em><a href="<?=$bqsr['titleurl']?>" rel="nofollow"><img src="<?=$bqr[titlepic]?>" class="img-fluid" alt="<?=$bqr['title']?>"></a></em>
<span>
<strong><a href="<?=$bqsr['titleurl']?>" rel="nofollow"><?=$bqr['title']?></a></strong>
<p><?=$bqr['smalltext']?></p>
</span>
</div>
</div>
[/e:loop]
{$dbtbpre}ecms_sitenav 数据表
order by rand() 随机
limit 6 数量
-
上一篇
帝国CMS排行榜调用标签(24小时排行、本周排行、本月排行)
[e:loop={0,9,4,0,'newstime>UNIX_TIMESTAMP()-86400*30','onclick desc'}]<li><a href="<?=$bqsr['titleurl']?>"><?=$bqr['title']?></a
- 下一篇
帝国CMS用灵动标签随机调取关键字相同的文章
[e:loop={'news',10,3,0,"keyboard like '%$navinfor[keyboard]%' and id<>$navinfor[id]",'rand() desc'}] < a href="<?=$bqsr['titleurl