この foreach を使用して youtube ビデオ ギャラリーを構築しますが、各行に 3 つのビデオを表示したい..3 回ループしてから次の行に移動して 3 回ループするように指定する方法...すべてのループを構築する必要はありません一行で..助けてくれてありがとう
table id="tblThumbsLayout" cellpadding="0" cellspacing="6">
<tr>
<?php foreach ($vcats as $vcat) { ?>
<td class="tdImg">
<div>
<?php echo '<iframe class="youtube-player" type="text/html" width=" 200 " height=" 100 " src="http://www.youtube.com/embed/' . $vcat['Video']['link'] . '"></iframe>' ;?>
<div class="text"><?php echo '<b>'. $vcat['Video']['title'].'</b>' ; ?></div>
</div>
</td>
<?php } ?>
</tr>
</table>