来源: 互联网 日期: 2020-07-13 20:22:48
帝国CMS高级应用-灵动标签之循环子栏目导航
[e:loop={"select classid,classname,islast from {$dbtbpre}enewsclass where bclassid='0' and showclass=0 order by myorder,classid ASC limit 11",0,24,0}]<?php$classurl=sys_ReturnBqClassname($bqr,9);//取得栏目地址?><li><a href="<?=$classurl?>" target="_blank" class="a"><span><?=$bqr[classname]?></span></a><?phpif(!$bqr[islast]) //判断是否终极栏目{?> <ul> <?php //取得栏目下的子栏目 $newsclass=$empire->query("select classid,classname from ".$dbtbpre."enewsclass where bclassid=".$bqr[classid]." order by myorder,classid desc limit 11"); while($classr=$empire->fetch($newsclass)) { $classrurl=sys_ReturnBqClassname($classr,9); //取得子栏目地址 ?> <li class="b"><a href="<?=$classrurl?>"><?=$classr[classname]?></a></li> <?php } ?> </ul><?php}?></li>[/e:loop]