basic-php-07-gallery.php / php
<?php //connect to the database link) or die (mysql_error()); ImageThumb = <html> <head> <title>Welcome to our Photo Gallery</title> </head> <body> <p align="center">Click on any image to see it full sized.</p> <table align="center"> <tr> <td align="center">Image</td> <td align="center">Caption</td> <td align="center">Uploaded By</td> <td align="center">Date Uploaded</td> </tr> <?php //get the thumbs getpic = mysql_query("SELECT * FROM images") or die(mysql_error()); while (getpic)) { extract(<tr>\n"; echo "<td><a href=\"".ImageDir . <img src=\"" . ImageThumb . </a></td>\n"; echo "<td>" . image_caption . "</td>\n"; echo "<td>" . </td>\n"; echo "<td>" . image_date . "</td>\n"; echo "</tr>\n"; } ?> </table> </body> </html>
(C) Æliens 20/2/2008
You may not copy or print any of this material without explicit permission of the author or the publisher. In case of other copyright issues, contact the author.