Hello Robert

I got the download to work in most browsers, but it seems like there's a
strange behaviour from Mozilla-based browsers that I can't find a workaround
to. The problem is that when forcing the browser to download a JPEG image
(with extension .jpg), it displays a save-as box with the correct filename
suffixed with .asp.

For example, if I force the browser to download a file names
'danisco_factory.jpg', the browser displays a save-as dialog with the
filename 'danisco_factory.jpg.asp' instead.

I'm using the following code (which works). Please note that I haven't
included everything from the code. The only problem I have is as described
above. I have tried all sorts of content-types without luck.

'## DOWNLOAD CODE - WATCH FOR WRAPPING
Response.AddHeader "Content-Disposition", "attachment; filename=" & Chr(34)
& GetFileName(strFileName) & Chr(34) Response.ContentType =
"application/x-unknown"
Response.CacheControl = "public"
Response.BinaryWrite GetBinaryFile(Server.MapPath("/images/" & strImageSize
& "/" & strFileName))

Thanks in advance!

with regards
anders l. borum � [EMAIL PROTECTED]
the sphereworx / monoliner experience
--


---
You are currently subscribed to activeserverpages as: [email protected]
To unsubscribe send a blank email to [EMAIL PROTECTED]

Reply via email to