views:

353

answers:

3

Hi everyone! Unfortunately I've a problem with IE =( I have a service on IIS that returns me a wav file. So if I go to the URL of the service, IE tries to play returned wav file with Window Media Player.

Can I set any setting in the IE (7 or 8) to deny it play wav file with WMP and allow only show Open \ Save \ Cancel dialog?

Usually I use Firefox and it has parameters to set actions for different MIME type. Is there anything similar with IE?

+2  A: 

I've not tried it, but does adding

Content-Disposition=attachment

to the response header fields help?

jdelStrother
Oh, man!Thank you very much. it works! Whoaaa!!!
nbulba
+1  A: 

Why not just make IIS serve wav files with application/octet-stream mime type?

Kalmi
A: 

If Kalmi's answer doesn't work and you're on IE8, you can also try adding this to the response header:

Response.AddHeader("X-Content-Type-Options", "nosniff");

Not sure if that will kill IE's MIME handling all-together, but it's another thing to try.

AJ