Safari 2.0.0.4 appends .html to pdf files

G

Gerrit Horeis

Hi NG,

I've a Problem with users who want to download DB-stored pdf files
("document.pdf"). The download is processed by an aspx-page which
Response.BinaryWrites the file to the client. but on safari 2.0.0.4
(and MacOs 10.4.9) the file is renamed to Document.pdf.html. Safari
1.xx does it all right.

I've set the ContentType and appended the right headers.

Response.ContentType = SqlDr["ContentType"].ToString();
Response.AppendHeader("Content-Disposition", "attachment; filename=\""
+ FileName + "\"");
Response.AppendHeader("Content-Length", OrgSize);

Can anybody please help?

--
Gerrit Horeis

Software Developer
CI-Gate Development & Consulting GmbH
http://www.ci-gate.de
 
K

kaza

frequently browsers open several tcp connections to server to spead up
downloads, and then somethings can go wrong if you are streming
content to client.


put debuger on the start "page" and check if this is the case, try
detecting it (by storing some values into session to indicate that
user already hava an open stream) and reject second connection. try
testing it with very small files.

I do not know if you can tell client "not to do that"

regards

if you have any questions please send cc on my emailadress as I am not
frequently reading news
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,767
Messages
2,569,572
Members
45,045
Latest member
DRCM

Latest Threads

Top