django-rest-framework-csv icon indicating copy to clipboard operation
django-rest-framework-csv copied to clipboard

IE11 Does not Download CSV, Chrome on Windows saves file as ".txt"

Open lylepratt opened this issue 11 years ago • 3 comments
trafficstars

There seems to be some mime-type/content-type issues with this renderer. On my Mac, I have no issues, however Windows users experience problems with both Chrome and IE11. On Chrome, the file is downloaded without an extension, and on IE11, the contents are just rendered to the browser.

lylepratt avatar Aug 21 '14 15:08 lylepratt

The answer on this page seems to indicate the problem: http://stackoverflow.com/questions/1382604/what-to-set-as-mimetype-for-csv-files-to-open-in-spreadsheet-applications

We need to set the Content-Disposition and the filename.

lylepratt avatar Aug 21 '14 15:08 lylepratt

Ping

lylepratt avatar Jan 09 '15 22:01 lylepratt

This issue also affects Chrome on windows.

lylepratt avatar Jan 09 '15 22:01 lylepratt