迅睿CMS框架是一款PHP8高性能·简单易用的CMS开源开发框架,基于MIT开源许可协议发布,免费且不限制商业使用,是免费开源的产品,以万端互联为设计理念,支持的微信公众号、小程序、APP客户端、移动端网站、PC网站等多终端式管理系统。
联系官方销售客服
1835022288
028-61286886
我这里个tab切换选项卡,我用这个循环
{category module=share pid=0 id=9,10,11,14 return=t}调出来的栏目顺序是对的
但是为什么用这个循环{module module=article catid=9,10,11,14 num=12}调出来的顺序是反的,变成了14,11,10,9,内容完全不对应了
求解答~
<div class="sec-panel-head"> <ul class="list tabs j-newslist" data-type="image data-per_page=12"> {category module=share pid=0 id=9,10,11,14 return=t} <li class="tab"><a href="javascript:;"><strong>{$t.name}</strong></a></li> {/category} </ul> </div> {module module=article catid=9,10,11,14 num=12} <ul class="post-loop post-loop-image cols-3 tab-wrap"> <li class="item"> <div class="item-inner"> <div class="item-img"> <a class="item-thumb" href="{$t['url']}" title="{$t['title']}" target="_blank"> <img class="attachment-post-thumbnail size-post-thumbnail wp-post-image j-lazy" alt="{$t['title']}" src="{dr_thumb($t['thumb'], 100, 100)}"> </a> </div> <h2 class="item-title"> <a href="{$t['url']}">{$t['title']}</a></h2> <div class="item-meta-author"><a class="avatar j-user-card">占地:<span style="color: #990000;font-weight: bold">{$t['zhandi']}</span>平</a> <div class=item-meta-right>{dr_date($t['_inputtime'], 'Y-m-d')}</div> </div> </div> </li> <li class="load-more-wrap"> <a href="{dr_cat_value('article', $t['catid'], 'url')}"><div class="btn load-more j-load-more">点击查看更多</div></a> </li> </ul> {/module}
<div class="sec-panel-head"> <ul class="list tabs j-newslist" data-type="image data-per_page=12"> {category module=share pid=0 id=9,10,11,14 return=t} <li class="tab"><a href="javascript:;"><strong>{$t.name}</strong></a></li> {/category} </ul> </div> {loop $return $c} // 循环上面的结果集 {module module=article catid=$c.id num=12} <ul class="post-loop post-loop-image cols-3 tab-wrap"> <li class="item"> <div class="item-inner"> <div class="item-img"> <a class="item-thumb" href="{$t['url']}" title="{$t['title']}" target="_blank"> <img class="attachment-post-thumbnail size-post-thumbnail wp-post-image j-lazy" alt="{$t['title']}" src="{dr_thumb($t['thumb'], 100, 100)}"> </a> </div> <h2 class="item-title"> <a href="{$t['url']}">{$t['title']}</a></h2> <div class="item-meta-author"><a class="avatar j-user-card">占地:<span style="color: #990000;font-weight: bold">{$t['zhandi']}</span>平</a> <div class=item-meta-right>{dr_date($t['_inputtime'], 'Y-m-d')}</div> </div> </div> </li> <li class="load-more-wrap"> <a href="{dr_cat_value('article', $t['catid'], 'url')}"><div class="btn load-more j-load-more">点击查看更多</div></a> </li> </ul> {/module} {/loop}