<var id="xvh3p"><noframes id="xvh3p"><var id="xvh3p"></var><listing id="xvh3p"><strike id="xvh3p"><listing id="xvh3p"></listing></strike></listing>
<var id="xvh3p"><strike id="xvh3p"><var id="xvh3p"></var></strike></var><th id="xvh3p"><strike id="xvh3p"><th id="xvh3p"></th></strike></th>
<span id="xvh3p"><noframes id="xvh3p"><dl id="xvh3p"></dl>
<span id="xvh3p"><noframes id="xvh3p">
<dl id="xvh3p"><noframes id="xvh3p">
<listing id="xvh3p"><noframes id="xvh3p"><listing id="xvh3p"><strike id="xvh3p"><listing id="xvh3p"></listing></strike></listing><th id="xvh3p"><strike id="xvh3p"><th id="xvh3p"></th></strike></th>
<th id="xvh3p"><strike id="xvh3p"></strike></th>
<dl id="xvh3p"><noframes id="xvh3p">
<th id="xvh3p"><noframes id="xvh3p">

观点

互联网+时代,说建站,谈运营与网络营销

织梦CMS统计当前栏目下子栏目数量的实现方法

时间:2020-12-15

今天在给一客户做网站时,需要用到统计子栏目数量。主要是利用{dede:field.typeid/}这个标签实现。
标签如下:
{dede:field.typeid runphp='yes'}
$id = @me;
global $dsql;
$sql="select COUNT(id) as num from dede_arctype WHERE reid=$id";
$row=$dsql->GetOne($sql);
@me= $row['num'];
{/dede:field.typeid}
特别需要注意红色字体。先引入$dsql,然后就可以直接使用DEDE自带的类了。
$row=$dsql->GetOne($sql);   在这里等于
$query=mysql_query($sql);
$row=mysql_fetch_array($query);
0
首页
案例
关于
联系