IE所支持的MIME类型列表,不支持JSON

在做文件上传的处理,发现在IE下会弹出‘下载服务器返回给浏览器的json代码‘, 其它非IE内核浏览器正常,后来发现,ie是不支持application/json的,所以在服务器端改回了text/html就行了。

IE9及以下目前所支持的mime类型,摘抄下来以备后用。

Known MIME Types

MIME TypeDescription
text/plainPlain text. Default if data is primarily text and no other type detected.
text/htmlHTML. Default if common tags detected and server does not supply image/* type.
text/xmlXML data. Default if data specifies <?xml with an unrecognized DTD.
text/richtextRich Text Format (RTF).
text/scriptletWindows script component.
audio/x-aiffAudio Interchange File, Macintosh.
audio/basicAudio file, UNIX.
audio/midWindows Internet Explorer 7 and later. MIDI sequence.
audio/wavPulse Code Modulation (PCM) Wave audio, Windows.
image/gifGraphics Interchange Format (GIF).
image/jpegJPEG image.
image/pjpegDefault type for JPEG images.
image/pngInternet Explorer 7 and later. Portable Network Graphics (PNG).
image/x-pngInternet Explorer 7 and later. Default type for PNG images.
image/tiffTagged Image File Format (TIFF) image.
image/bmpBitmap (BMP) image.
image/x-xbitmapRemoved from Windows Internet Explorer 8.
image/x-jgAOL Johnson-Grace compressed file.
image/x-emfEnhanced Metafile (EMF).
image/x-wmfWindows Metafile Format (WMF).
video/aviAudio-Video Interleaved (AVI) file.
video/mpegMPEG stream file.
application/octet-streamBinary file. Default if data is primarily binary.
application/postscriptPostScript (.ai, .eps, or .ps) file.
application/base64Base64-encoded bytes.
application/macbinhex40BinHex for Macintosh.
application/pdfPortable Document Format (PDF).
application/xmlXML data. Must be server-supplied. See also "text/xml" type.
application/atom+xmlInternet Explorer 7 and later. Atom Syndication Format feed.
application/rss+xmlInternet Explorer 7 and later. Really Simple Syndication (RSS) feed.
application/x-compressedUNIX tar file, Gzipped.
application/x-zip-compressedCompressed archive file.
application/x-gzip-compressedGzip compressed archive file.
application/javaJava applet.
application/x-msdownloadExecutable (.exe or .dll) file.


转载于:https://my.oschina.net/monsterslayer/blog/262747

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值