Bug 25578

Summary: Safari adds ".html" to downloaded file despite Content Disposition header
Product: WebKit Reporter: Rob Lewis <groblewis>
Component: DOMAssignee: Nobody <webkit-unassigned>
Status: RESOLVED INVALID    
Severity: Normal CC: alex, cdumez
Priority: P2    
Version: 525.x (Safari 3.2)   
Hardware: Mac   
OS: All   

Description Rob Lewis 2009-05-05 15:15:18 PDT
Trying to download a small XML file to be saved by the browser. Its MIME type is "application/x-madx" and its Content Disposition header declares an explicit filename like "MyFile.madx". 

In spite of this, Safari downloads the file as "MyFile.madx.html". 

FireFox handles it correctly, saving the file as "MyFile.madx".
Comment 1 Mark Rowe (bdash) 2009-05-06 00:17:37 PDT
*** Bug 25580 has been marked as a duplicate of this bug. ***
Comment 2 Alexander Romanovich 2010-01-11 11:59:19 PST
I hit this one today, unfortunately (release and r53036). Are there any workarounds? I'm going to tell my application to send application/force-download for WebKit users for now...

Note that in the original description, I don't think the specific mime type being sent matters, the result is always the same.
Comment 3 Alexey Proskuryakov 2010-01-11 17:01:25 PST
This issue is not in open source WebKit, please report it to Apple via <http://bugreport.apple.com> (free registration required). Sorry that we overlooked this bug when it was filed originally.
Comment 4 Alexander Romanovich 2010-01-12 06:22:17 PST
rdar://7533251
Comment 5 Lucas Forschler 2019-02-06 09:03:10 PST
Mass moving XML DOM bugs to the "DOM" Component.