這篇內(nèi)容主要試用ECMS6.5,往后的版本就出來測試了:
0、先來標(biāo)準(zhǔn)的loop靈動標(biāo)簽說明
[e:loop={欄目ID/專題ID,顯示條數(shù),操作類型,只顯示有標(biāo)題圖片,附加SQL條件,顯示排序}]
1、調(diào)用相同作者發(fā)布的信息
[e:loop={"news",5,18,0,"userid='".$navinfor[userid]."' and ismember=1",""}]
2、調(diào)用相同標(biāo)題分類的信息
[e:loop={"selfinfo",5,0,0,"ttid='$navinfor[ttid]'",""}]
3、調(diào)用相同父欄目的信息
[e:loop={$class_r[$GLOBALS[navclassid]][bclassid],5,0,0,"",""}]
4、調(diào)用當(dāng)前欄目的下級欄目列表
[e:loop={"select * from [!db.pre!]enewsclass where bclassid='$GLOBALS[navclassid]'",10,24,0,"",""}]
5、調(diào)用當(dāng)前欄目的同級欄目列表
[e:loop={"select * from [!db.pre!]enewsclass where bclassid='".$class_r[$GLOBALS[navclassid]][bclassid]."'",10,24,0,"",""}]
6、調(diào)用上級欄目的同級欄目列表
<?php
$bclassid=$class_r[$GLOBALS[navclassid]][bclassid];
$bbclassid=$class_r[$bclassid][bclassid];
?>
[e:loop={"select * from [!db.pre!]enewsclass where bclassid='$bbclassid'",10,24,0,"",""}]
7、調(diào)用上上級欄目的同級欄目列表
[e:loop={"select * from [!db.pre!]enewsclass where bclassid='".$class_r[$GLOBALS[navclassid]]."'",10,24,0,"",""}]
8、調(diào)用上一級父欄目名,直接加到loop中即可,欄目ID同理
<?php
$bclassid=$class_r[$bqr[classid]]['bclassid'];
$bclassname=$class_r[$bclassid][classname];
echo $bclassname;
?>
父欄目名:<?=$bclassname?>
9、調(diào)用上上一級父欄目ID、欄目名、鏈接,直接加到loop中即可
<?php
$bclassid=$class_r[$GLOBALS[navclassid]][bclassid];
$bbclassid=$class_r[$bclassid][bclassid];
?>
父欄目ID:<?=$bbclassid?>
父欄目名:<?=$class_r[$bbclassid][classname];?>
父欄目鏈接:<a href="/e/public/ClassUrl?classid=<?=$bbclassid?>"> <?=$class_r[$bbclassid][classname];?> </a>
版權(quán)聲明: 本站資源均來自互聯(lián)網(wǎng)或會員發(fā)布,如果侵犯了您的權(quán)益請與我們聯(lián)系,我們將在24小時內(nèi)刪除!謝謝!
轉(zhuǎn)載請注明: 帝國ECMS6.5靈動標(biāo)簽匯集