$mimetypelist["csm"] = "application/cu-seeme";
$mimetypelist["cu"] = "application/cu-seeme";
$mimetypelist["tsp"] = "application/dsptype";
$mimetypelist["xls"] = "application/excel";
$mimetypelist["spl"] = "application/futuresplash";
$mimetypelist["hqx"] = "application/mac-binhex40";
$mimetypelist["doc"] = "application/msword";
$mimetypelist["dot"] = "application/msword";
$mimetypelist["bin"] = "application/octet-stream";
$mimetypelist["oda"] = "application/oda";
$mimetypelist["pdf"] = "application/pdf";
$mimetypelist["pgp"] = "application/pgp-signature";
$mimetypelist["ps"] = "application/postscript";
$mimetypelist["ai"] = "application/postscript";
$mimetypelist["eps"] = "application/postscript";
$mimetypelist["ppt"] = "application/powerpoint";
$mimetypelist["rtf"] = "application/rtf";
$mimetypelist["wp5"] = "application/wordperfect5.1";
$mimetypelist["zip"] = "application/zip";
$mimetypelist["wk"] = "application/x-123";
$mimetypelist["bcpio"] = "application/x-bcpio";
$mimetypelist["pgn"] = "application/x-chess-pgn";
$mimetypelist["cpio"] = "application/x-cpio";
$mimetypelist["deb"] = "application/x-debian-package";
$mimetypelist["dcr"] = "application/x-director";
$mimetypelist["dir"] = "application/x-director";
$mimetypelist["dxr"] = "application/x-director";
$mimetypelist["dvi"] = "application/x-dvi";
$mimetypelist["pfa"] = "application/x-font";
$mimetypelist["pfb"] = "application/x-font";
$mimetypelist["gsf"] = "application/x-font";
$mimetypelist["pcf"] = "application/x-font";
$mimetypelist["pcf.Z"] = "application/x-font";
$mimetypelist["gtar"] = "application/x-gtar";
$mimetypelist["tgz"] = "application/x-gtar";
$mimetypelist["hdf"] = "application/x-hdf";
$mimetypelist["phtml"] = "application/x-httpd-php";
$mimetypelist["pht"] = "application/x-httpd-php";
$mimetypelist["php"] = "application/x-httpd-php";
$mimetypelist["php3"] = "application/x-httpd-php3";
$mimetypelist["phps"] = "application/x-httpd-php3-source";
$mimetypelist["php3p"] = "application/x-httpd-php3-preprocessed";
$mimetypelist["class"] = "application/x-java";
$mimetypelist["latex"] = "application/x-latex";
$mimetypelist["frm"] = "application/x-maker";
$mimetypelist["maker"] = "application/x-maker";
$mimetypelist["frame"] = "application/x-maker";
$mimetypelist["fm"] = "application/x-maker";
$mimetypelist["fb"] = "application/x-maker";
$mimetypelist["book"] = "application/x-maker";
$mimetypelist["fbdoc"] = "application/x-maker";
$mimetypelist["mif"] = "application/x-mif";
$mimetypelist["com"] = "application/x-msdos-program";
$mimetypelist["exe"] = "application/x-msdos-program";
$mimetypelist["bat"] = "application/x-msdos-program";
$mimetypelist["dll"] = "application/x-msdos-program";
$mimetypelist["nc"] = "application/x-netcdf";
$mimetypelist["cdf"] = "application/x-netcdf";
$mimetypelist["pac"] = "application/x-ns-proxy-autoconfig";
$mimetypelist["o"] = "application/x-object";
$mimetypelist["pl"] = "application/x-perl";
$mimetypelist["pm"] = "application/x-perl";
$mimetypelist["shar"] = "application/x-shar";
$mimetypelist["swf"] = "application/x-shockwave-flash";
$mimetypelist["swfl"] = "application/x-shockwave-flash";
$mimetypelist["sit"] = "application/x-stuffit";
$mimetypelist["sv4cpio"] = "application/x-sv4cpio";
$mimetypelist["sv4crc"] = "application/x-sv4crc";
$mimetypelist["tar"] = "application/x-tar";
$mimetypelist["gf"] = "application/x-tex-gf";
$mimetypelist["pk"] = "application/x-tex-pk";
$mimetypelist["PK"] = "application/x-tex-pk";
$mimetypelist["texinfo"] = "application/x-texinfo";
$mimetypelist["texi"] = "application/x-texinfo";
$mimetypelist["~"] = "application/x-trash";
$mimetypelist["%"] = "application/x-trash";
$mimetypelist["bak"] = "application/x-trash";
$mimetypelist["old"] = "application/x-trash";
$mimetypelist["sik"] = "application/x-trash";
$mimetypelist["t"] = "application/x-troff";
$mimetypelist["tr"] = "application/x-troff";
$mimetypelist["roff"] = "application/x-troff";
$mimetypelist["man"] = "application/x-troff-man";
$mimetypelist["me"] = "application/x-troff-me";
$mimetypelist["ms"] = "application/x-troff-ms";
$mimetypelist["ustar"] = "application/x-ustar";
$mimetypelist["src"] = "application/x-wais-source";
$mimetypelist["wz"] = "application/x-wingz";
$mimetypelist["au"] = "audio/basic";
$mimetypelist["snd"] = "audio/basic";
$mimetypelist["mid"] = "audio/midi";
$mimetypelist["midi"] = "audio/midi";
$mimetypelist["mpga"] = "audio/mpeg";
$mimetypelist["mpega"] = "audio/mpeg";
$mimetypelist["mp2"] = "audio/mpeg";
$mimetypelist["mp3"] = "audio/mpeg";
$mimetypelist["m3u"] = "audio/mpegurl";
$mimetypelist["aif"] = "audio/x-aiff";
$mimetypelist["aiff"] = "audio/x-aiff";
$mimetypelist["aifc"] = "audio/x-aiff";
$mimetypelist["gsm"] = "audio/x-gsm";
$mimetypelist["ra"] = "audio/x-pn-realaudio";
$mimetypelist["rm"] = "audio/x-pn-realaudio";
$mimetypelist["ram"] = "audio/x-pn-realaudio";
$mimetypelist["rpm"] = "audio/x-pn-realaudio-plugin";
$mimetypelist["wav"] = "audio/x-wav";
$mimetypelist["gif"] = "image/gif";
$mimetypelist["ief"] = "image/ief";
$mimetypelist["jpeg"] = "image/jpeg";
$mimetypelist["jpg"] = "image/jpeg";
$mimetypelist["jpe"] = "image/jpeg";
$mimetypelist["png"] = "image/png";
$mimetypelist["tiff"] = "image/tiff";
$mimetypelist["tif"] = "image/tiff";
$mimetypelist["ras"] = "image/x-cmu-raster";
$mimetypelist["bmp"] = "image/x-ms-bmp";
$mimetypelist["pnm"] = "image/x-portable-anymap";
$mimetypelist["pbm"] = "image/x-portable-bitmap";
$mimetypelist["pgm"] = "image/x-portable-graymap";
$mimetypelist["ppm"] = "image/x-portable-pixmap";
$mimetypelist["rgb"] = "image/x-rgb";
$mimetypelist["xbm"] = "image/x-xbitmap";
$mimetypelist["xpm"] = "image/x-xpixmap";
$mimetypelist["xwd"] = "image/x-xwindowdump";
$mimetypelist["csv"] = "text/comma-separated-values";
$mimetypelist["html"] = "text/html";
$mimetypelist["htm"] = "text/html";
$mimetypelist["mml"] = "text/mathml";
$mimetypelist["txt"] = "text/plain";
$mimetypelist["rtx"] = "text/richtext";
$mimetypelist["tsv"] = "text/tab-separated-values";
$mimetypelist["h++"] = "text/x-c++hdr";
$mimetypelist["hpp"] = "text/x-c++hdr";
$mimetypelist["hxx"] = "text/x-c++hdr";
$mimetypelist["hh"] = "text/x-c++hdr";
$mimetypelist["c++"] = "text/x-c++src";
$mimetypelist["cpp"] = "text/x-c++src";
$mimetypelist["cxx"] = "text/x-c++src";
$mimetypelist["cc"] = "text/x-c++src";
$mimetypelist["h"] = "text/x-chdr";
$mimetypelist["csh"] = "text/x-csh";
$mimetypelist["c"] = "text/x-csrc";
$mimetypelist["java"] = "text/x-java";
$mimetypelist["moc"] = "text/x-moc";
$mimetypelist["p"] = "text/x-pascal";
$mimetypelist["pas"] = "text/x-pascal";
$mimetypelist["etx"] = "text/x-setext";
$mimetypelist["sh"] = "text/x-sh";
$mimetypelist["tcl"] = "text/x-tcl";
$mimetypelist["tk"] = "text/x-tcl";
$mimetypelist["tex"] = "text/x-tex";
$mimetypelist["ltx"] = "text/x-tex";
$mimetypelist["sty"] = "text/x-tex";
$mimetypelist["cls"] = "text/x-tex";
$mimetypelist["vcs"] = "text/x-vcalendar";
$mimetypelist["vcf"] = "text/x-vcard";
$mimetypelist["dl"] = "video/dl";
$mimetypelist["fli"] = "video/fli";
$mimetypelist["gl"] = "video/gl";
$mimetypelist["mpeg"] = "video/mpeg";
$mimetypelist["mpg"] = "video/mpeg";
$mimetypelist["mpe"] = "video/mpeg";
$mimetypelist["qt"] = "video/quicktime";
$mimetypelist["mov"] = "video/quicktime";
$mimetypelist["asf"] = "video/x-ms-asf";
$mimetypelist["asx"] = "video/x-ms-asf";
$mimetypelist["avi"] = "video/x-msvideo";
$mimetypelist["movie"] = "video/x-sgi-movie";
$mimetypelist["vrm"] = "x-world/x-vrml";
$mimetypelist["vrml"] = "x-world/x-vrml";
$mimetypelist["wrl"] = "x-world/x-vrml";

当从浏览器返回一个文件时,需要指定ContentType,以下是Office2007对应的值:

  "application/vnd.openxmlformats-officedocument.wordprocessingml.template" (for .dotx files)

  "application/vnd.openxmlformats-officedocument.presentationml.presentation" (for .pptx files)

  "application/vnd.openxmlformats-officedocument.presentationml.slideshow" (for .ppsx files)

  "application/vnd.openxmlformats-officedocument.presentationml.template" (for .potx files)

  "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet" (for .xlsx files)

  "application/vnd.openxmlformats-officedocument.spreadsheetml.template" (for .xltx files)

  相对于Office2003是这样的

  Response.ContentType = "application/vnd.ms-excel"

常用mimetype的更多相关文章

  1. intent-filter 之 data 「scheme, host, port, mimeType, path, pathPrefix, pathPattern」

    之前一直搞不很明白 AndroidManifest.xml 中 activity 标签下的 intent-filter 中 data 标签的属性含义,今天认真看了 Dev Guide,又在网上查询了大 ...

  2. Android应用中实现系统“分享”接口

    在android下各种文件管理器中,我们选择一个文件,点击分享可以看到弹出一些app供我们选择,这个是android系统分享功能,我们做的app也可以出现在这个列表中. 第一步:在Manifest.x ...

  3. Android隐式启动匹配:action,category,data

    简介 Android开发中,Activity,Service 和 BroadcastReceiver 启动有两种方式,显示启动和隐式启动. 为方便下面描述,我以Activity启动为例. 显示启动便是 ...

  4. HTTP Header 入门详解

    什么是HTTP Headers HTTP是"Hypertext Transfer Protocol"的所写,整个www都在使用这种协定,几乎你在流览器里看到的大部分内容都是通过ht ...

  5. 转:什么是 HTTP Headers?

    什么是HTTP Headers HTTP是“Hypertext Transfer Protocol”的所写,整个万维网都在使用这种协议,几乎你在浏览器里看到的大部分内容都是通过http协议来传输的,比 ...

  6. http headers

    什么是HTTP Headers HTTP是“Hypertext Transfer Protocol”的所写,整个万维网都在使用这种协议,几乎你在浏览器里看到的大部分内容都是通过http协议来传输的,比 ...

  7. GET、POST详解 --转自http://hi.baidu.com/richarwu/item/bd43633a6ba62986b611dbcd

    HTTP Get,Post请求详解 请求类型 三种最常见的请求类型是:GET,POST 和 HEAD GET:获取一个文档 大部分被传输到浏览器的html,images,js,css, … 都是通过G ...

  8. web.xml常用元素配置

    tomcat服务器: tomcat是一个WEB服务器,所有的j2ee WEB程序可以在此处运行. tomcat服务器是一个符合j2ee标准的WEB服务器.则J2ee的EJB程序无法在此处运行. 如果要 ...

  9. Tengine 常用模块使用介绍

    Tengine 和 Nginx Tengine简介 从2011年12月开始:Tengine是由淘宝网发起的Web服务器项目.它在Nginx的基础上,针对大访问量网站的需求,添加了很多高级功能 和特性. ...

随机推荐

  1. Maya pywin32

    Maya 2011 – 2013 64-bit: maya-64-bit-pywin32.zipMaya 2011 – 2013 32-bit: maya-32-bit-pywin32.zipMaya ...

  2. GIF文件转换为头文件工具

    目的: GIF文件转为头文件 举例: 用UE打开GIF文件,如下图所示:图1 test.gif文件将上面文件内容转化为头文件,放到一个数组里面,内容如下:图2 test.h文件 思路: 从上面可知,将 ...

  3. Coursera《machine learning》--(8)神经网络表述

    本笔记为Coursera在线课程<Machine Learning>中的神经网络章节的笔记. 八.神经网络:表述(Neural Networks: Representation) 本节主要 ...

  4. BZOJ 3677 连珠线

    Description 在达芬奇时代,有一个流行的儿童游戏称为连珠线.当然,这个游戏是关于珠子和线的.线是红色或蓝色的,珠子被编号为\(1\)到\(n\).这个游戏从一个珠子开始,每次会用如下方式添加 ...

  5. 【HDOJ】1422 重温世界杯

    简单题. #include <stdio.h> #define MAXN 100005 int wi[MAXN], li[MAXN]; ]; int main() { int n, tot ...

  6. HDU-4952 Number Transformation

    http://acm.hdu.edu.cn/showproblem.php?pid=4952 Number Transformation Time Limit: 2000/1000 MS (Java/ ...

  7. HDU-1969 Pie

    http://acm.hdu.edu.cn/showproblem.php?pid=1969 Pie Time Limit: 5000/1000 MS (Java/Others)    Memory ...

  8. Linux学习笔记8——VIM编辑器的使用

    在ubuntu中,敲入命令行:sudo apt-get install vim,然后输入系统密码,确认Y,即可下载vim 按下vim,在后面跟上文件的路径,即可进入文件到编辑模式,如果不存在该文件,将 ...

  9. Bzoj 2748: [HAOI2012]音量调节 动态规划

    2748: [HAOI2012]音量调节 Time Limit: 3 Sec  Memory Limit: 128 MBSubmit: 1234  Solved: 777[Submit][Status ...

  10. msql修改字符

    我申请了一个jsp空间,把数据库传上去,编码如下mysql> show variables like '%char%';+--------------------------+--------- ...