Closed Bug 229785 Opened 21 years ago Closed 21 years ago

tries download of page instead of rendering it

Categories

(Core Graveyard :: File Handling, defect)

defect
Not set
minor

Tracking

(Not tracked)

VERIFIED FIXED
mozilla1.7alpha

People

(Reporter: heinrich, Assigned: Biesinger)

References

()

Details

Attachments

(2 files)

User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.6b) Gecko/20031208 Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.6b) Gecko/20031208 If I type in that URL, the "how to handle" dialog occurs (download, default application, open with application ...) Reproducible: Always Steps to Reproduce: 1. 2. 3. Expected Results: render the page without dialog.
Attached file Hardcopy of the dialog
confirming 20031230 Linux. Web Sniffer shows it sends a content-disposition header: [...] content-disposition: name="68c77dcf.html"; filename="68c77dcf.html" [...] http://web-sniffer.net/?url=http%3A%2F%2Fwww.emprise.de%2Femprise.shtml&gzip=yes fwiw, Opera 7.50 P1 (Linux) doesn't prompt user to save file and display it fine.
OS: Windows 2000 → All
(mid-air collision) That's because the browsers a series of redirections, and the last one (the text/html file that you want tos ee) is send with these headers : HTTP/1.1 200 OK^M Date: Wed, 31 Dec 2003 16:01:25 GMT^M Server: Apache/1.3.23 (Unix) mod_jk/1.1.0 PHP/4.1.0^M content-description: 68c77dcf.html^M Set-Cookie: JSESSIONID=F2357289D8624034F9A510E335F2B4E1;Path=/^M content-disposition: name="68c77dcf.html"; filename="68c77dcf.html"^M content-location: 68c77dcf.html^M Transfer-Encoding: chunked^M Content-Type: text/html^M So there's a "Content-Disposition" header inside, and that's why Mozilla tries to download the file instead of displaying. The error is actually on the webserver's side : it should use the 'inline' parameter, and not the 'attachment' (which is the default used by Mozilla, although it should really be included too). Or it shouldn't use Content-Disposition at all, because it doesn't belong here. Bug 185618 ?
*** This bug has been marked as a duplicate of 185618 ***
Status: UNCONFIRMED → RESOLVED
Closed: 21 years ago
Resolution: --- → DUPLICATE
actually wait, we may want to support that. we already special case this: Content-Disposition: filename=foo [...] we may want to extend that to name=foo
Status: RESOLVED → UNCONFIRMED
Resolution: DUPLICATE → ---
Assignee: general → file-handling
Status: UNCONFIRMED → NEW
Component: Browser-General → File Handling
Ever confirmed: true
QA Contact: general → ian
Comment on attachment 138207 [details] [diff] [review] patch I'd say we should do this.
Attachment #138207 - Flags: review?(bz-vacation)
Assignee: file-handling → cbiesinger
Target Milestone: --- → mozilla1.7alpha
Status: NEW → ASSIGNED
Comment on attachment 138207 [details] [diff] [review] patch r=bzbarsky
Attachment #138207 - Flags: review?(bz-vacation) → review+
Attachment #138207 - Flags: superreview?(darin)
Comment on attachment 138207 [details] [diff] [review] patch sr=darin
Attachment #138207 - Flags: superreview?(darin) → superreview+
thanks, checked in alternate testcase url: http://biesi.damowmow.com/mime.php?do=1&type=text/html&disposition=name=foo&filename=&quote=1& (should be displayed with the patch, not without it)
Status: ASSIGNED → RESOLVED
Closed: 21 years ago21 years ago
Resolution: --- → FIXED
I believe adding support for the (unspecced) "name" parameter was a bad idea; back when it was added, no other UA supported it. As of today, only Chrome does as well (apparently copying from Firefox), but in a slightly different way. See http://greenbytes.de/tech/tc2231/#attwithnamepct). I think this should be removed from both FF and Chrome, unless somebody is willing to precisely specify what it does, and how it's better than "filename".
Hardware: x86 → All
(In reply to Julian Reschke from comment #12) > I think this should be removed from both FF and Chrome, unless somebody is > willing to precisely specify what it does, and how it's better than > "filename". -> Bug 776339
Depends on: 776339
Product: Core → Core Graveyard
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: