View Full Version : PHP: problem in retrieving image from mysql database!!!
zyklone
January 7th, 2005, 04:22 AM
i just want to ask...i had known already on how to upload an image using mysql database...but i have a problem on how could i retrieve these images to my webpage...i just want to post it on my webpage using <img src=...> .could you please give to me the code on how. thank you to all.
mbo108
January 7th, 2005, 08:49 AM
well if your photos are physically residing in a folder named "images" (very common) and they're in a database table that you have already queried, you can do something like
<img src="images/<?php echo $queryName['image']?>" />
zyklone
January 8th, 2005, 03:06 AM
well if your photos are physically residing in a folder named "images" (very common) and they're in a database table that you have already queried, you can do something like
<img src="images/<?php echo $queryName['image']?>" />
no! my photos are not in a folder they are in the database..my question is how could i post my photos came from database to my webpage. because my photos are aploaded in database...
Digitalosophy
January 8th, 2005, 04:08 AM
no! my photos are not in a folder they are in the database..my question is how could i post my photos came from database to my webpage. because my photos are aploaded in database...
images aren't "stored" in a database, the path's and file name are
SmoothDime
January 8th, 2005, 04:29 AM
the raw data that makes up the images can be "stored" in a database. here's a tutorial with some discussion:
tutorial (http://www.liquidpulse.net/articles/php/images/storing_and_retrieve_images_from_a_mysql_database/creating_the_image)
Powered by vBulletin® Version 4.1.10 Copyright © 2012 vBulletin Solutions, Inc. All rights reserved.