Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

If I had a link to a file such as http://www.example.com/test.abc

How do I ensure that when the link is clicked the file is downloaded, instead of the file contents just getting rendered in the browser.

In tests, Chrome and Firefox seem to download the file, but IE renders the content.

share|improve this question
add comment

1 Answer

up vote 1 down vote accepted

IE guesses mime-types. You need to set the mime-type for the .abc extension in your webserver to:

application/force-download

Which should force the browser to download it.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.