Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Images

Status
Not open for further replies.

rubbersoul

IS-IT--Management
Joined
Mar 20, 2003
Messages
88
Location
CA
What I want to do is display an image from a database...I've gotten the image up to the db but when I try and display it...it displays the binary (a bunch of gibberish text) instead of the image...how can I fix this. Im using php and mysql

Are you loaded yet?
 
change the content type when displaying the image...but it is best not to store images on the db...store in folder and keep text path/name to image in db...much better

then call for image is simple

$image=$rows['image'];

echo &quot;<img src=\&quot;$image\&quot;>&quot;;

hth

Bastien

cat, the other other white meat
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top