代码一:多个sinfo分开调用其子信息
<?php $ctsql=$empire->query("select * from {$dbtbpre}dptag_sinfo where classid='$navinfor[classid]' and id='$navinfor[id]' limit 99"); while($ctr=$empire->fetch($ctsql)){ ?> [e:indexloop={"select * from {$dbtbpre}dptag_sinfo where ztid='$ctr[ztid]' limit 10",0,11,'',''}] <a href="<?=$bqsr['titleurl']?>" target="_blank"><?=$bqr['title']?></a> <br> [/e:indexloop] <? } ?>
代码二:多个子sinfo,混合调用其子信息
[e:indexloop={"select * from {$dbtbpre}dptag_sinfo where ztid in (select ztid from {$dbtbpre}dptag_sinfo where classid='$navinfor[classid]' and id='$navinfor[id]') limit 10",0,11,'',''}] <a href="<?=$bqsr['titleurl']?>" target="_blank"><?=$bqr['title']?></a> <br> [/e:indexloop]
$thisztid=Sinfo的id; $sznum=$empire->gettotal("select count(*) as total from {$dbtbpre}dptag_sinfo where ztid='$thisztid'");
不同页面,$thisztid值是不同的,根据具体情况来写。
©2013-2019 DP1037.COM东坡网,致力于帝国cms插件和二次开发,为帝国cms加油! 备案号:粤ICP备14036885号-2