Thread: PhotoAlbum!
View Single Post
  #2 (permalink)  
Old August 4th, 2007, 02:37 AM
Imar's Avatar
Imar Imar is offline
Wrox Author
Points: 72,073, Level: 100
Points: 72,073, Level: 100 Points: 72,073, Level: 100 Points: 72,073, Level: 100
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jun 2003
Location: Utrecht, Netherlands.
Posts: 17,089
Thanks: 80
Thanked 1,587 Times in 1,563 Posts
Default

Hi Ossy,

I haven't looked at your source yet, but I think I know what the problem is. When you store the files on disk, you can easily refer to them using the *path* stored in the database.

However, when you store them in the database, you cannot directly stream the image "blob" into an <img> tag. Instead, you need a separate page that accepts the ID of the image and streams it to the browser.

You may want to take a look at this article:

http://imar.spaanjaars.com/QuickDocId.aspx?quickdoc=414

The file ViewFile.aspx probably shows you exactly what you need.

Cheers,

Imar

---------------------------------------
Imar Spaanjaars
http://Imar.Spaanjaars.Com
Everyone is unique, except for me.
Author of ASP.NET 2.0 Instant Results and Beginning Dreamweaver MX / MX 2004
Want to be my colleague? Then check out this post.