问题:
循环二级栏目名称时,能否控制 显示的条数?比如: 控制只调用 2条 子栏目 或者 4条。
在 return=c1 后面 加 num 时(比如 num=6),会异常,会重复调出一个子栏目。
num | 表示显示数量,支持定点查询,例如1,2表示从第1条记录开始,共显示2条数据 |
{category module=share id=1,6,5,59 return=c}
- {$c.name} {if $c.child} {category module=share pid=$c.id return=c1}
- {$c1.name} {/category} {/if}
官方提醒:使用category栏目循环标签的生成工具,填写参数就可以生成相关的代码,每个参数后面都有用法解释
答案:
{category module=share pid=$c.id num=2 return=c1}
{category module=share pid=$c.id return=c1}
回复@官方研发技术-西门 换了一个位置,
。从后面 换到前面,生效了。 感谢。 🙏
@tunfly:参考你的 位置,功能正常了。