I have found the following asp.net code to be very useful when serving files from a database:
Response.AppendHeader("content-disposition", "attachment; filename=" + fileName);
This lets the user save the file to their computer and then decide how to use it, instead of the browser trying to use the file.
What other things can be done with the content-disposition response header?
0
to0x1F
) – Pacerier Feb 5 '15 at 9:39