2 ms·
Thanks. These days it looks like a reasonable solution is to just call the file "download.ext" for anything older than IE9. When I was trying to implement a s
by jcampbell1 14y ago
Thanks. These days it looks like a reasonable solution is to just call the file "download.ext" for anything older than IE9.
When I was trying to implement a solution to this problem years ago, what I thought would take 20 minutes of coding, started to look like a week of research and testing, and I gave up.
- kijin 14y agoIn my experience, IE6-8 can handle UTF-8 filenames if (1) the extension is alphanumeric; (2) you percent-encode the rest of the filename, making sure that whitespace is encoded as "%20" rather than "+"; and (3) you put the whole thing between double quotes. Use RFC2231 for all other browsers, although slightly older versions of Chrome and Safari might cause trouble from time to time. But nowadays I'm so comfortable with just using the URL that the above encoding schemes just feel like unnecessary hassle. HTTP was designed to display the filename in plain sight in the URL, not bury it in a header. Use it as intended and even IE will happily comply.