473,385 Members | 1,736 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

Safari 2.0.0.4 appends .html to pdf files

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

May 29 '07 #1
1 1909
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


On May 29, 12:03 pm, Gerrit Horeis <Gerrit.Hor...@web.dewrote:
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 GmbHhttp://www.ci-gate.de

May 30 '07 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

5
by: Lachlan Hunt | last post by:
Hi, Can somebody with a mac please check if my website style sheet works reasonably well in Safari, and possibly suggest a fix for any problems? I tried the iCapture website to get a screen...
4
by: Bernard | last post by:
Hi, I am suddenly getting Safari script errors with the following user agent: Mozilla/5.0 (Macintosh; U; PPC Mac OS X; en) AppleWebKit/125.2 (KHTML, like Gecko) Safari/125.8 In a...
5
by: joaopedrogoncalves | last post by:
Hi, I want to load an external javascript file, get its results and stick them inside a <div> block. I also want to do this in several places on a web page. This way the browser doesn't have...
4
by: Paul W | last post by:
Hi - can someone point me to info on the issues/resolutions of supporting the safari browser? To help me understand, if I was developing pages in say FrontPage, what attributes would I set for...
4
by: metoikos | last post by:
I've scoured the web (clumsily, I'm sure) for information on the difficulties I am having, checked my markup in validators, and had a friend with more CSS clue look over it, but I haven't had any...
5
by: Bill Cohagan | last post by:
I'm having some serious difficulties with my ASP.Net 2.0 app rendering in Safari 2.0.3. The most immediate problem is that the menu control doesn't seem to work at all, particularly the use of...
4
by: twigster | last post by:
Hi, I've a pb with utf8 encoding with safari or firefox. I retrieve the response of a XMLHttpRequest and depending if I use safari or firefox I can't manage to get characters like "éàç" to...
7
by: David Stone | last post by:
Run into something recently that has left me a little puzzled. According to the examples in section 13.6.1 of html 4.01... <http://www.w3.org/TR/html401/struct/objects.html#h-13.6.1.1> I...
3
by: Brad | last post by:
I have an aspx page that is sending pdf files to client browsers: it uses a filestream to read the pdf file and response.binarywrite to send content to the browser. This has worked great for years...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.