Posted by Chung Leong on 11/24/08 11:28
Malcolm Dew-Jones wrote:
> If the output of the php script is sent as "content-type: something/odd"
> then opera would correctly display a download dialog, whereas explorer
> would likely ignore the content-type and use the file extension plus what
> it "sees" in the data to guess it is supposed to be text/html and so
> display it.
Some clarification: IE will always sniff the content stream for the
file type. It only considers the content-type header when the test
returns inconclusive result (e.g. text/html vs. text/plain). The file
extension doesn't play a role at all. You can see for yourself by
saving a .txt file with the line "GIF89a is the signature of GIF files"
and retrieving it through IE.
Navigation:
[Reply to this message]
|