私はこのスクリプトを持っています:
 <?php 
                $count = 0;
        foreach(glob("images/{*.gif,*.jpg,*.png,*.jpeg,*.bmp}", GLOB_BRACE) as $image)
        while ($image)
        {
            if($count==3)
            {
               print "</tr>";
               $count = 0;
            }
            if($count==0)
               print "<tr>";
               print "<td>";
            ?>
               <img src="<?php echo $image;?>" width="80" height="80"/>
                <?php
            $count++;
            print "</td>";
        }
        if($count>0)
           print "</tr>";
        ?>
フォルダーから画像(この場合は「画像」)を取得し、それらを3行に表示することになっています。しかし、それは 1 つの画像を 1000000 回表示します。これを修正するにはどうすればよいですか? 私はそれを修正しようとしましたが、私が知っているのは、問題が「while」行にあるということだけです。