V6.5在原來(lái)所有信息調(diào)用標(biāo)簽基礎(chǔ)上增加了兩個(gè)標(biāo)簽參數(shù):“附加SQL條件”和“顯示排序”。
以靈動(dòng)標(biāo)簽為例,6.5版標(biāo)簽語(yǔ)法為:
[e:loop={欄目ID/專(zhuān)題ID,顯示條數(shù),操作類(lèi)型,只顯示有標(biāo)題圖片,附加SQL條件,顯示排序}]模板代碼內(nèi)容[/e:loop]例子:調(diào)用標(biāo)題包含“cms”的新聞[e:loop={"select * from phome_ecms_news where title like '%cms%' and checked=1 order by newstime desc limit 10",10,24,0}]<a href="<?=$bqsr[titleurl]?>" target="_blank"><?=$bqr[title]?></a><br>[/e:loop]而6.5版本用下面就可以實(shí)現(xiàn)上面效果:[e:loop={'news',10,18,0,"title like '%cms%'"}]<a href="<?=$bqsr[titleurl]?>" target="_blank"><?=$bqr[title]?></a><br>[/e:loop][e:loop={"select * from phome_ecms_news where checked=1 order by diggtop desc limit 10",10,24,0}]<a href="<?=$bqsr[titleurl]?>" target="_blank"><?=$bqr[title]?></a><br>[/e:loop][e:loop={'news',10,18,0,'','diggtop desc'}]<a href="<?=$bqsr[titleurl]?>" target="_blank"><?=$bqr[title]?></a><br>[/e:loop]新聞熱點(diǎn)
疑難解答
圖片精選