View Full Version : Output Pictures from Database
10-27-2005, 06:31 AM
How do i output pictures from my sql database using asp?
the rest of my data are being able to be displayed except the pictures.
10-27-2005, 07:07 AM
Are you using Response.BinaryWrite instead of Response.Write?
10-27-2005, 07:19 AM
Yes, i am using response.binarywrite as found from some websites. My datatype is varchar,that is correct right? And not image.?
10-27-2005, 07:36 AM
The datatype should be BLOB (http://www.microsoft.com/technet/prodtechnol/sql/2000/reskit/part3/c1161.mspx)
10-27-2005, 07:48 AM
how am i supposed to enter the image path in my database?
is it supposed to be this way - "images/cake.jpg" with datatype varchar?
10-27-2005, 07:49 AM
im using ms sql, which doesnt have datatype blob .. it only has image varchar... and so on.
10-27-2005, 10:58 AM
I thought you were saving the image itself in the db, not the path.
10-28-2005, 01:56 AM
it's ok i got it already.I was really dumb - i was missing out the tag <img src> .. instead my tag looked just like this only - <%=RS.Fields("Images")%> and the rest similarly <%=RS.Fields("Name")%> - i forgot to add in <img src=">in front of the rs.fields("image") .. lol
Powered by vBulletin® Version 4.2.2 Copyright © 2017 vBulletin Solutions, Inc. All rights reserved.