Forum Moderators: coopster
Now, to display the last 8 images added I would use:
$result = mysql_query("SELECT * FROM recentimages ORDER BY id DESC LIMIT 8",$connect);
However, if I start the loop with an image whose src is the result of the query in a table it's going to repeat the table each time with a different image.
I have no clue how to get it into a table thats 4 columns by 2 rows displaying 1 of the 8 images in each cell, please help if you can. Thanks in advance.
After you hace constructed your array, just echo the variuous elements, so for example, at first cell you will show array element 0, at next cell, array element 1 and so forth
There are quite a few examples on the forum that describe how to loop and display images using MySQL and PHP. A quick search turned up this example that may help ...
[webmasterworld.com...]