{if $data} {php $len=count($data) } <tr> {loop $data $r} <li>...</li> {if $n%3==0&&$n!=$len}</tr><tr>{/if} {/loop} </tr> {/if}
举一反三:输出2条循环tr
{if $data} {php $len=count($data) } <tr> {loop $data $r} <li>...</li> {if $n%2==0&&$n!=$len}</tr><tr>{/if} {/loop} </tr> {/if}