帝国CMS模板php灵动标签循环栏目带文章(一级栏目、子栏目、子栏目下的文章)

内容摘要
帝国CMS模板php灵动标签循环栏目带文章(一级栏目、子栏目、子栏目下的文章)
文章正文
代码如下:
<table width="500" border="1" align="center" cellpadding="0" cellspacing="0" bordercolor="#CC33CC">
<?php
$ecms_bq_sql=sys_ReturnEcmsLoopBq('select classid,classname,classpath,wburl from [!db.pre!]enewsclass where bclassid=0 and showclass=0 order by myorder',0,24,0);
$bqno=0;
while($bqr=$empire->fetch($ecms_bq_sql))
{
        $bqsr=sys_ReturnEcmsLoopStext($bqr);
        $classid=($bqr[classid]);
        $classurl=sys_ReturnBqClassname($bqr,9);
        $bqno++;
        ?>
  <tr>
    <td><h1><a href="<?=$classurl?>"  target="_blank"><?=$bqr[classname]?></a></h1></td>
  </tr>
<?php
        $ecms_bq_sql2=sys_ReturnEcmsLoopBq("select classid,classname from {$dbtbpre}enewsclass where bclassid=$classid order by myorder,classid asc",0,24,0);         
$bqno2=0;
        while($bqr2=$empire->fetch($ecms_bq_sql2))
        {
                $bqsr2=sys_ReturnEcmsLoopStext($bqr2);
                $classurl=sys_ReturnBqClassname($bqr2,9);
                $classid2=($bqr2[classid]);
                $bqno2++;
                ?>
<tr>
    <td height="54"><h4 style="margin-left:180px;"><a href="<?=$classurl?>" target="_blank"><?=$bqr2[classname]?></a></h4></td>
  </tr>
            <tr>
      <td> 
             <?php
        $ecms_bq_sql3=sys_ReturnEcmsLoopBq($classid2,10,0,0);
        $bqno3=0;
        while($bqr3=$empire->fetch($ecms_bq_sql3))
        {
                $bqsr3=sys_ReturnEcmsLoopStext($bqr3);
                $bqno3++;
                ?>
                  <li><a href="<?=$bqsr3[titleurl]?>" target="_blank"><?=$bqr3[title]?></a></li>
        <?php
        }
        ?>
</td>
</tr>
                <?php
        }
        ?>
<?php
}
?>
</table>
代码注释

作者:喵哥笔记

IDC笔记

学的不仅是技术,更是梦想!