Well here's the way I do it. I store the image name in the DB, not the path. So that's pretty self-explanitory, eh. Insert your relavent data into the table.
Ok then you want to query your table. We'll deal with only the image name field for simplicity here.
// Connect to the DB and select your database
$dbconn = mysql_connect("localhost", "DB_USER_NAME", "DB_PASSWORD");
mysql_select_db("DATABASE_NAME",$dbconn);
Next up, query the table and display the result. Here is where as a personal choice I echo back the img tag, the image path, and the file name that we query from the table.
$sql = "SELECT img_field_name FROM MY_TABLE";
$result = mysql_query($sql);
while($rs = mysql_fetch_array($result)){
echo "<img src=\"YOUR/PATH/TO/IMAGE/".$rs['imagefieldname']."\">";
}
Hope that gives you the gist of the query and display?