I m using this code to show latest 4 pictures from mysql database.: <?php echo "<table border=\"0\" width=\"100%\" align=\"center\">"; include "mysql.php"; { mysql_connect($host, $username, $password) or die(); mysql_select_db("$databasename") or die(); $result=mysql_query("SELECT * from mus_img ORDER BY imgid DESC LIMIT 10"); $numrows = mysql_num_rows($result); while ($results = mysql_fetch_array($result)) { $imgid=$results['imgid']; $imgname=$results['imgname']; $imgtum=$results['imgtum']; echo "<td width=\"25%\" height=\"1\" align=\"center\"><a href=\"img.php?imgid=$imgid&count=1\"><img src=\"$imgtum\" alt=\"$imgname\"></a></td>"; } } echo "</table>"; ?> PHP: Now i want to show 12 pics in 3 rows.Means 4 pics in ach row. Any one can help me.
This may sound stupid, but how do you get more then 1 result. For example I put Limit 10 and the end of the query but it only displays 1 result. Any1 got any examples ?