|
帝国CMS调用当前栏目一共多少篇文章数量两种方法
- 方法1:[totaldata]$GLOBALS[navclassid],0,0[/totaldata]
复制代码- 方法2:<?php
- $classid=$GLOBALS[navclassid]; //获取当前栏目ID
- $r=$empire->fetch1("select count(*) as total from {$dbtbpre}ecms_news where classid='$classid'");
- echo $r['total'];
- ?>
复制代码
|
上一篇:首页用灵动标签调用留言和留言人头像下一篇:宝塔面板CentOS 8.x安装免费防火墙后nginx无法启动修改方法
|