Here's what I have...(I posted this yesterday too to no avail):
index.php3:
<html>
<img src="thumb.php3?id=1">
</html>
thumb.php3:
<?php
$db = mysql_connect("localhost","xxxxx","xxxxx");
mysql_select_db("xxxxx",$db);
$sql="SELECT thumb FROM gallery WHERE id=".$_GET['id'];
$query=mysql_query($sql,$db);
while($row=mysql_fetch_array($query))
{
$thumb=$row["thumb"];
echo "thumbs/$thumb";
}
?>
The end result I want is for thumb.php3 to place an image's file name into the img src tag.
Am I doing this correctly?