Answer the question
In order to leave comments, you need to log in
How to properly give a file for IE9?
I do it like this:
Response.AddHeader("Content-Disposition", "attachment; filename=\"" + filename + "\"");
Response.AddHeader("Content-Type", type);
Response.ContentEncoding = Encoding.Default;
Response.HeaderEncoding = Encoding.Default;
Response.WriteFile(path);
Answer the question
In order to leave comments, you need to log in
If you have access to the web server settings, then you can do it radically, make a rewrite URL so that your script is before the file name, for example:
/script_hadle/file.ext
Try
Content-Type: file/file; name="video.mpg"
Content-disposition: attachment; filename="video.mpg"
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question