C# 之 HttpResponse 类

      Response 对象,派生自HttpResponse 类,该类封装来自 ASP.NET 操作的 HTTP 响应信息。存在于System.Web命名空间下。

      注:MIME(Multipurpose Internet Mail Extensions)多用途互联网邮件扩展类型就是设定某种扩展名的文件用一种应用程序来打开的方式类型,当该扩展名文件被访问的时候,浏览器会自动使用指定应用程序来打开。多用于指定一些客户端自定义的文件名,以及一些媒体文件打开方式。 

      (一)构造函数:public HttpResponse(TextWriter writer)
      (二)属性:

名称用法说明
BufferResponse.Buffer  = true

获取或设置一个值,该值指示是否缓冲输出并在处理完整个响应之后发送它。

(true or false)

BufferOutputResponse.BufferOutput = true;

获取或设置一个值,该值指示是否缓冲输出并在处理完整个页之后发送它。

(true or false)

Cache Response.Cache.SetExpires(DateTime.Now.AddSeconds(60));
Response.Cache.SetCacheability(HttpCacheability.Public);
Response.Cache.SetValidUntilExpires(false);
Response.Cache.VaryByParams["Category"] = true;

if (Response.Cache.VaryByParams["Category"])
{
   //...
}
获取网页的缓存策略(例如:过期时间、保密性设置和变化条款)。
CacheControl 获取或设置与 HttpCacheability枚举值之一匹配的 Cache-Control HTTP 标头。
CharsetResponse.Charset == "iso-8859-2"获取或设置输出流的 HTTP 字符集。
ClientDisconnectedToken 获取客户端断开时去除的 CancellationToken对象。
ContentEncodingResponse.ContentEncoding.EncodingName获取或设置输出流的 HTTP 字符集。
ContentType

Response.ContentType = "image/jpeg";  等同于

Response.AddHeader("content-type", "image/jpeg");

获取或设置输出流的 HTTP MIME 类型,来区分不同种类的数据。
CookiesHttpCookie MyCookie = new HttpCookie("LastVisit");
DateTime now = DateTime.Now;
MyCookie.Value = now.ToString();
MyCookie.Expires = now.AddHours(1);
Response.Cookies.Add(MyCookie);
获取响应 Cookie 集合。
Expires 

获取或设置在浏览器上缓存的页过期之前的分钟数。如果用户在页面过期之前返回到该页,则显示缓存的版本。提供 Expires是为了与 ASP 的早期版本兼容。

ExpiresAbsolute 

获取或设置从缓存中移除缓存信息的绝对日期和时间。

提供 ExpiresAbsolute是为了与 ASP 的早期版本兼容。

Filter Response.Filter = new UpperCaseFilterStream(Response.Filter);获取或设置一个包装筛选器对象,该对象用于在传输之前修改 HTTP 实体主体。
HeaderEncoding 获取或设置一个 Encoding象,该对象表示当前标头输出流的编码。
Headers 获取响应标头的集合。
IsClientConnected Response.IsClientConnected获取一个值,通过该值指示客户端是否仍连接在服务器上。(true or false)
IsRequestBeingRedirected 获取一个布尔值,该值指示客户端是否正在被传输到新的位置。
Output if (IsPostBack)
{
     Server.HtmlEncode(txtSubmitString.Text, Response.Output);
}
启用到输出 HTTP 响应流的文本输出。
OutputStream bmp.Save(Response.OutputStream, ImageFormat.Jpeg);启用到输出 HTTP 内容主体的二进制输出。
RedirectLocation Response.RedirectLocation = "http://www.newurl.com ";获取或设置 Http Location 标头的值。
Status 设置返回到客户端的 Status 栏。
StatusCode Response.StatusCode != 200获取或设置返回给客户端的输出的 HTTP 状态代码。
StatusDescription Response.StatusDescription != "OK"获取或设置返回给客户端的输出的 HTTP 状态字符串。
SubStatusCode context.Response.SubStatusCode = 99;获取或设置一个限定响应的状态代码的值。
SupportsAsyncFlush 获取一个值,该值指示集合是否支持异步刷新操作。
SuppressContent Response.SuppressContent = true;获取或设置一个值,该值指示是否将 HTTP 内容发送到客户端。
SuppressFormsAuthenticationRedirect 获取或设置指定重定向至登录页的 forms 身份验证是否应取消的值。
TrySkipIisCustomErrors 获取或设置一个值,该值指定是否禁用 IIS 7.0 自定义错误。(true or false)

      (三)方法:   

名称用法说明
AddCacheDependency(params CacheDependency[] dependencies)CacheDependency authorsDependency = new CacheDependency("authors.xml");      
Response.AddCacheDependency(authorsDependency);
将一组缓存依赖项与响应关联,这样,如果响应存储在输出缓存中并且指定的依赖项发生变化,就可以使该响应失效。
AddCacheItemDependencies(ArrayList cacheKeys)ArrayList deps = new ArrayList();
deps.Add("bookData");
deps.Add("authorData");    
Response.AddCacheItemDependencies(deps);
使缓存响应的有效性依赖于缓存中的其他项。
AddCacheItemDependencies(string[] cacheKeys) 使缓存项的有效性依赖于缓存中的另一项。
AddCacheItemDependency(string cacheKey)

 Response.AddCacheItemDependency("bookData");

使缓存响应的有效性依赖于缓存中的其他项。
AddFileDependencies(ArrayList filenames)

ArrayList fileList = new ArrayList(); fileList.Add(file1); fileList.Add(file2);

Response.AddFileDependencies(fileList);

将一组文件名添加到文件名集合中,当前响应依赖于该集合。
AddFileDependencies(string[] filenames)String[] FileNames = new String[3];
FileNames[0] = "Test.txt";
FileNames[1] = "Test2.txt";
FileNames[2] = "Test3.txt";
Response.AddFileDependencies(FileNames);
将一个文件名数组添加到当前响应依赖的文件名集合中。
AddFileDependency(string filename)String FileName = "C:\\Files\\F1.txt";
Response.AddFileDependency(FileName);
将单个文件名添加到文件名集合中,当前响应依赖于该集合。
AddHeader(string name,string value)

Response.AddHeader("Content-Type","image/jpeg");  等同于

Response.ContentType = "image/jpeg";

将 HTTP 头添加到输出流。提供 AddHeader 是为了与 ASP 的早期版本兼容。
AppendCookie(HttpCookie cookie)HttpCookie MyCookie = new HttpCookie("LastVisit");
MyCookie.Value = DateTime.Now.ToString();
Response.AppendCookie(MyCookie);
基础结构。将一个 HTTP Cookie 添加到内部 Cookie 集合。
AppendHeader(string name, string value ) Response.AppendHeader("CustomAspNetHeader", "Value1");将 HTTP 头添加到输出流。
AppendToLog(stringparam)Response.AppendToLog("Page delivered");将自定义日志信息添加到 Internet 信息服务 (IIS) 日志文件。
ApplyAppPathModifier(string virtualPath)string urlConverted = Response.ApplyAppPathModifier("TestPage.aspx");如果会话使用 Cookieless 会话状态,则将该会话 ID 添加到虚拟路径中,并返回组合路径。如果不使用 Cookieless 会话状态,则 ApplyAppPathModifier 返回原始的虚拟路径。
BeginFlush(AsyncCallback callback,
Object state)
public IAsyncResult BeginFlush(AsyncCallback callback,
Object state)
向客户端发送当前所有缓冲的响应。
BinaryWrite(byte[] buffer)byte[] Buffer = new byte[(int)FileSize];
MyFileStream.Read(Buffer, 0, (int)FileSize);
MyFileStream.Close();
Response.Write("<b>File Contents: </b>");
Response.BinaryWrite(Buffer);
将一个二进制字符串写入 HTTP 输出流。
Clear()Response.Clear();清除缓冲区流中的所有内容输出。
ClearContent()Response.ClearContent();清除缓冲区流中的所有内容输出。
ClearHeaders()Response.ClearHeaders();清除缓冲区流中的所有头。
Close()Response.Close();关闭到客户端的套接字连接。
DisableKernelCache()public void DisableKernelCache()禁用当前响应的内核缓存。
DisableUserCache()public void DisableUserCache()禁用 IIS 用户-方式来缓存反映。
End()Response.End();将当前所有缓冲的输出发送到客户端,停止该页的执行,并引发 EndRequest 事件。
EndFlushpublic void EndFlush(IAsyncResult asyncResult)完成异步刷新操作。
Equals(Object obj)Console.WriteLine("person1a and person1b: {0}", ((object) person1a).Equals((object) person1b));
Console.WriteLine("person1a and person2: {0}", ((object) person1a).Equals((object) person2));
确定指定的对象是否等于当前对象。 (继承自 Object。)
Flush()Response.Flush();向客户端发送当前所有缓冲的输出。
GetHashCode()public virtual int GetHashCode()作为默认哈希函数。 (继承自 Object。)
GetType()Console.WriteLine("n1 and n2 are the same type: {0}",
Object.ReferenceEquals(n1.GetType(), n2.GetType()));
获取当前实例的 Type。 (继承自 Object。)
Pics(string value )Response.Pics( 
"(pics-1.1 <http://www.icra.org/ratingsv02.html> " + "comment <ICRAonline EN v2.0> " + 
"l r (nz 1 vz 1 lz 1 oz 1 cz 1) " + "<http://www.rsac.org/ratingsv01.html> " +
" l r (n 0 s 0 v 0 l 0))");
将一个 HTTP PICS-Label 标头追加到输出流。
Redirect(string url)Response.Redirect("http://www.microsoft.com/gohere/look.htm");将请求重定向到新 URL 并指定该新 URL。
Redirect(string url, bool endResponse)Response.Redirect("default.aspx", false);将客户端重定向到新的 URL。指定新的 URL 并指定当前页的执行是否应终止。
RedirectPermanent(string url)public void RedirectPermanent(string url)执行从所请求 URL 到所指定 URL 的永久重定向。
RedirectPermanent(string url, bool endResponse)public void RedirectPermanent(string url,bool endResponse)执行从所请求 URL 到所指定 URL 的永久重定向,并提供用于完成响应的选项。
RedirectToRoute(Object routeValues)Response.RedirectToRoute(new { productid = "1", category = "widgets" });使用路由参数值将请求重定向到新 URL。
RedirectToRoute(RouteValueDictionary routeValues)Response.RedirectToRoute((new RouteValueDictionary {productId="1", category="widgets"});使用路由参数值将请求重定向到新 URL。
RedirectToRoute(string routeName)Response.RedirectToRoute("Products");使用路由名称将请求重定向到新 URL。
RedirectToRoute(string routeName, Object routeValues)Response.RedirectToRoute("Product",new { productid = "1", category = "widgets" });使用路由参数值和路由名称将请求重定向到新 URL。
RedirectToRoute(string routeName, RouteValueDictionary routeValues)Response.RedirectToRoute("Product",(new RouteValueDictionary {productId="1", category="widgets"}));使用路由参数值和路由名称将请求重定向到新 URL。
RedirectToRoutePermanent(Object routeValues)Response.RedirectToRoutePermanent(new { productid = "1", category = "widgets" });使用路由参数值执行从所请求 URL 到新 URL 的永久重定向。
RedirectToRoutePermanent(RouteValueDictionary routeValues)Response.RedirectToRoutePermanent(new RouteValueDictionary {productId="1", category="widgets"});使用路由参数值执行从所请求 URL 到新 URL 的永久重定向。
RedirectToRoutePermanent(string routeName) Response.RedirectToRoutePermanent("Products");使用路由名称执行从所请求 URL 到新 URL 的永久重定向。
RedirectToRoutePermanent(string routeName, Object routeValues)Response.RedirectToRoutePermanent("Product",
new { productid = "1", category = "widgets" });
使用路由参数值以及与新 URL 对应的路由的名称执行从所请求 URL 到新 URL 的永久重定向。
RedirectToRoutePermanent(string routeName, RouteValueDictionary routeValues) Response.RedirectToRoutePermanent("Product",new RouteValueDictionary {productId="1", category="widgets"});使用路由参数值和路由名称执行从所请求 URL 到新 URL 的永久重定向。
RemoveOutputCacheItem(string path)public static void RemoveOutputCacheItem(string path)从缓存中移除与默认输出缓存提供程序关联的所有缓存项。此方法是静态的。
RemoveOutputCacheItem(string path,
string providerName
)
public static void RemoveOutputCacheItem(string path,string providerName)使用指定的输出缓存提供程序移除与指定路径关联的所有输出缓存项。
SetCookie(HttpCookie cookie)MyCookie.Value = DateTime.Now.ToString();
Response.Cookies.Add(MyCookie);
基础结构。更新 Cookie 集合中的一个现有 Cookie。
ToString()public virtual string ToString()返回表示当前对象的字符串。 (继承自 Object。)
TransmitFile(string filename)public void TransmitFile(string filename)将指定的文件直接写入 HTTP 响应输出流,而不在内存中缓冲该文件。
TransmitFile(string, Int64, Int64)public void TransmitFile(string filename,long offset,long length)将文件的指定部分直接写入 HTTP 响应输出流,而不在内存中缓冲它。
Write(Char ch)char[] charArray = {'H', 'e', 'l', 'l', 'o', ',', ' ', 'w', 'o', 'r', 'l', 'd'};
Response.Write(';');
将一个字符写入 HTTP 响应输出流。
Write(Object obj) object obj = (object)13;
Response.Write(obj);
Object 写入 HTTP 响应流。
Write(string str)Response.Write("Hello " + Server.HtmlEncode(Request.QueryString["UserName"]) + "<br>");将一个字符串写入 HTTP 响应输出流。
Write(char[] buffer,int index,int count)Response.Write(charArray, 0, charArray.Length);将一个字符数组写入 HTTP 响应输出流。
WriteFile(string fileName)Response.Write("Please Login: <br>");
Response.WriteFile("login.txt");
将指定文件的内容作为文件块直接写入 HTTP 响应输出流。
WriteFile(string filename, bool readIntoMemory)Response.WriteFile("login.txt", true);将指定文件的内容作为内存块直接写入 HTTP 响应输出流。
WriteFile(IntPtr fileHandle, long offset,
long size
)
String FileName;
FileStream MyFileStream;
IntPtr FileHandle;
long StartPos = 0, FileSize;

FileName = "c:\\temp\\Login.txt";

MyFileStream = new FileStream(FileName, FileMode.Open);
FileHandle = MyFileStream.Handle;
FileSize = MyFileStream.Length;

Response.Write("<b>Login: </b>");
Response.Write("<input type=text id=user /> ");
Response.Write("<input type=submit value=Submit /><br><br>");

Response.WriteFile(FileHandle, StartPos, FileSize);

MyFileStream.Close();
将指定的文件直接写入 HTTP 响应输出流。
WriteFile(string fileName, Int64 offSet, Int64 size)String FileName;
FileInfo MyFileInfo;
long StartPos = 0, FileSize;

FileName = "c:\\temp\\login.txt";
MyFileInfo = new FileInfo(FileName);
FileSize = MyFileInfo.Length;

Response.Write("Please Login: <br>");
Response.WriteFile(FileName, StartPos, FileSize);
将指定的文件直接写入 HTTP 响应输出流。
WriteSubstitution(HttpResponseSubstitutionCallback callback)public void WriteSubstitution(HttpResponseSubstitutionCallback callback)允许将响应替换块插入响应,从而允许为缓存的输出响应动态生成指定的响应区域。

注意:HttpResponse 类的方法和属性通过 HttpApplication、HttpContext、Page和 UserControl类的 Response属性公开。

仅在回发情况(不包括异步回发情况)下才支持 HttpResponse 类的以下方法:Binary,WriteClear,ClearContent,ClearHeaders,Close,End,Flush,TransmitFile,Write,WriteFile,WriteSubstitution.

<%@ Page Language="C#" %>
<%@ import Namespace="System.Drawing" %>
<%@ import Namespace="System.Drawing.Imaging" %>
<%@ import Namespace="System.Drawing.Drawing2D" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<script runat="server">

    private void Page_Load(object sender, EventArgs e)
    {
        // 设置页面的ContentType为JPEG 文件
        //
        Response.ContentType = "image/jpeg";
        Response.Clear();

        // Buffer response so that page is sent
        // after processing is complete.
        Response.BufferOutput = true;

        // Create a font style.
        Font rectangleFont = new Font(
            "Arial", 10, FontStyle.Bold);

        // Create integer variables.
        int height = 100;
        int width = 200;

        // Create a random number generator and create
        // variable values based on it.
        Random r = new Random();
        int x = r.Next(75);
        int a = r.Next(155);
        int x1 = r.Next(100);

        // Create a bitmap and use it to create a
        // Graphics object.
        Bitmap bmp = new Bitmap(
            width, height, PixelFormat.Format24bppRgb);
        Graphics g = Graphics.FromImage(bmp);

        g.SmoothingMode = SmoothingMode.AntiAlias;
        g.Clear(Color.LightGray);

        // Use the Graphics object to draw three rectangles.
        g.DrawRectangle(Pens.White, 1, 1, width-3, height-3);
        g.DrawRectangle(Pens.Aquamarine, 2, 2, width-3, height-3);
        g.DrawRectangle(Pens.Black, 0, 0, width, height);

        // Use the Graphics object to write a string
        // on the rectangles.
        g.DrawString(
            "ASP.NET Samples", rectangleFont,
            SystemBrushes.WindowText, new PointF(10, 40));

        // Apply color to two of the rectangles.
        g.FillRectangle(
            new SolidBrush(
                Color.FromArgb(a, 255, 128, 255)),
            x, 20, 100, 50);

        g.FillRectangle(
            new LinearGradientBrush(
                new Point(x, 10),
                new Point(x1 + 75, 50 + 30),
                Color.FromArgb(128, 0, 0, 128),
                Color.FromArgb(255, 255, 255, 240)),
            x1, 50, 75, 30);

        // Save the bitmap to the response stream and
        // convert it to JPEG format.
        bmp.Save(Response.OutputStream, ImageFormat.Jpeg);

        // Release memory used by the Graphics object
        // and the bitmap.
        g.Dispose();
        bmp.Dispose();

        // Send the output to the client.
        Response.Flush();
    }

</script>
<html xmlns="http://www.w3.org/1999/xhtml" >
<head>
    <title>ASP.NET Example</title>
</head>
<body>
    <form id="form1" runat="server">
    </form>
</body>
</html>
View Code

 

附:Response的ContentType类型对照表

类型列表如下: 

文件扩展名Content-Type(Mime-Type)文件扩展名Content-Type(Mime-Type)
.*( 二进制流,不知道下载文件类型)application/octet-stream.tifimage/tiff
.001application/x-001.301application/x-301
.323text/h323.906application/x-906
.907drawing/907.a11application/x-a11
.acpaudio/x-mei-aac.aiapplication/postscript
.aifaudio/aiff.aifcaudio/aiff
.aiffaudio/aiff.anvapplication/x-anv
.asatext/asa.asfvideo/x-ms-asf
.asptext/asp.asxvideo/x-ms-asf
.auaudio/basic.avivideo/avi
.awfapplication/vnd.adobe.workflow.biztext/xml
.bmpapplication/x-bmp.botapplication/x-bot
.c4tapplication/x-c4t.c90application/x-c90
.calapplication/x-cals.catapplication/vnd.ms-pki.seccat
.cdfapplication/x-netcdf.cdrapplication/x-cdr
.celapplication/x-cel.cerapplication/x-x509-ca-cert
.cg4application/x-g4.cgmapplication/x-cgm
.citapplication/x-cit.classjava/*
.cmltext/xml.cmpapplication/x-cmp
.cmxapplication/x-cmx.cotapplication/x-cot
.crlapplication/pkix-crl.crtapplication/x-x509-ca-cert
.csiapplication/x-csi.csstext/css
.cutapplication/x-cut.dbfapplication/x-dbf
.dbmapplication/x-dbm.dbxapplication/x-dbx
.dcdtext/xml.dcxapplication/x-dcx
.derapplication/x-x509-ca-cert.dgnapplication/x-dgn
.dibapplication/x-dib.dllapplication/x-msdownload
.docapplication/msword.dotapplication/msword
.drwapplication/x-drw.dtdtext/xml
.dwfModel/vnd.dwf.dwfapplication/x-dwf
.dwgapplication/x-dwg.dxbapplication/x-dxb
.dxfapplication/x-dxf.ednapplication/vnd.adobe.edn
.emfapplication/x-emf.emlmessage/rfc822
.enttext/xml.epiapplication/x-epi
.epsapplication/x-ps.epsapplication/postscript
.etdapplication/x-ebx.exeapplication/x-msdownload
.faximage/fax.fdfapplication/vnd.fdf
.fifapplication/fractals.fotext/xml
.frmapplication/x-frm.g4application/x-g4
.gbrapplication/x-gbr.application/x-
.gifimage/gif.gl2application/x-gl2
.gp4application/x-gp4.hglapplication/x-hgl
.hmrapplication/x-hmr.hpgapplication/x-hpgl
.hplapplication/x-hpl.hqxapplication/mac-binhex40
.hrfapplication/x-hrf.htaapplication/hta
.htctext/x-component.htmtext/html
.htmltext/html.htttext/webviewhtml
.htxtext/html.icbapplication/x-icb
.icoimage/x-icon.icoapplication/x-ico
.iffapplication/x-iff.ig4application/x-g4
.igsapplication/x-igs.iiiapplication/x-iphone
.imgapplication/x-img.insapplication/x-internet-signup
.ispapplication/x-internet-signup.IVFvideo/x-ivf
.javajava/*.jfifimage/jpeg
.jpeimage/jpeg.jpeapplication/x-jpe
.jpegimage/jpeg.jpgimage/jpeg
.jpgapplication/x-jpg.jsapplication/x-javascript
.jsptext/html.la1audio/x-liquid-file
.larapplication/x-laplayer-reg.latexapplication/x-latex
.lavsaudio/x-liquid-secure.lbmapplication/x-lbm
.lmsffaudio/x-la-lms.lsapplication/x-javascript
.ltrapplication/x-ltr.m1vvideo/x-mpeg
.m2vvideo/x-mpeg.m3uaudio/mpegurl
.m4evideo/mpeg4.macapplication/x-mac
.manapplication/x-troff-man.mathtext/xml
.mdbapplication/msaccess.mdbapplication/x-mdb
.mfpapplication/x-shockwave-flash.mhtmessage/rfc822
.mhtmlmessage/rfc822.miapplication/x-mi
.midaudio/mid.midiaudio/mid
.milapplication/x-mil.mmltext/xml
.mndaudio/x-musicnet-download.mnsaudio/x-musicnet-stream
.mochaapplication/x-javascript.movievideo/x-sgi-movie
.mp1audio/mp1.mp2audio/mp2
.mp2vvideo/mpeg.mp3audio/mp3
.mp4video/mpeg4.mpavideo/x-mpg
.mpdapplication/vnd.ms-project.mpevideo/x-mpeg
.mpegvideo/mpg.mpgvideo/mpg
.mpgaaudio/rn-mpeg.mppapplication/vnd.ms-project
.mpsvideo/x-mpeg.mptapplication/vnd.ms-project
.mpvvideo/mpg.mpv2video/mpeg
.mpwapplication/vnd.ms-project.mpxapplication/vnd.ms-project
.mtxtext/xml.mxpapplication/x-mmxp
.netimage/pnetvue.nrfapplication/x-nrf
.nwsmessage/rfc822.odctext/x-ms-odc
.outapplication/x-out.p10application/pkcs10
.p12application/x-pkcs12.p7bapplication/x-pkcs7-certificates
.p7capplication/pkcs7-mime.p7mapplication/pkcs7-mime
.p7rapplication/x-pkcs7-certreqresp.p7sapplication/pkcs7-signature
.pc5application/x-pc5.pciapplication/x-pci
.pclapplication/x-pcl.pcxapplication/x-pcx
.pdfapplication/pdf.pdfapplication/pdf
.pdxapplication/vnd.adobe.pdx.pfxapplication/x-pkcs12
.pglapplication/x-pgl.picapplication/x-pic
.pkoapplication/vnd.ms-pki.pko.plapplication/x-perl
.plgtext/html.plsaudio/scpls
.pltapplication/x-plt.pngimage/png
.pngapplication/x-png.potapplication/vnd.ms-powerpoint
.ppaapplication/vnd.ms-powerpoint.ppmapplication/x-ppm
.ppsapplication/vnd.ms-powerpoint.pptapplication/vnd.ms-powerpoint
.pptapplication/x-ppt.prapplication/x-pr
.prfapplication/pics-rules.prnapplication/x-prn
.prtapplication/x-prt.psapplication/x-ps
.psapplication/postscript.ptnapplication/x-ptn
.pwzapplication/vnd.ms-powerpoint.r3ttext/vnd.rn-realtext3d
.raaudio/vnd.rn-realaudio.ramaudio/x-pn-realaudio
.rasapplication/x-ras.ratapplication/rat-file
.rdftext/xml.recapplication/vnd.rn-recording
.redapplication/x-red.rgbapplication/x-rgb
.rjsapplication/vnd.rn-realsystem-rjs.rjtapplication/vnd.rn-realsystem-rjt
.rlcapplication/x-rlc.rleapplication/x-rle
.rmapplication/vnd.rn-realmedia.rmfapplication/vnd.adobe.rmf
.rmiaudio/mid.rmjapplication/vnd.rn-realsystem-rmj
.rmmaudio/x-pn-realaudio.rmpapplication/vnd.rn-rn_music_package
.rmsapplication/vnd.rn-realmedia-secure.rmvbapplication/vnd.rn-realmedia-vbr
.rmxapplication/vnd.rn-realsystem-rmx.rnxapplication/vnd.rn-realplayer
.rpimage/vnd.rn-realpix.rpmaudio/x-pn-realaudio-plugin
.rsmlapplication/vnd.rn-rsml.rttext/vnd.rn-realtext
.rtfapplication/msword.rtfapplication/x-rtf
.rvvideo/vnd.rn-realvideo.samapplication/x-sam
.satapplication/x-sat.sdpapplication/sdp
.sdwapplication/x-sdw.sitapplication/x-stuffit
.slbapplication/x-slb.sldapplication/x-sld
.slkdrawing/x-slk.smiapplication/smil
.smilapplication/smil.smkapplication/x-smk
.sndaudio/basic.soltext/plain
.sortext/plain.spcapplication/x-pkcs7-certificates
.splapplication/futuresplash.spptext/xml
.ssmapplication/streamingmedia.sstapplication/vnd.ms-pki.certstore
.stlapplication/vnd.ms-pki.stl.stmtext/html
.styapplication/x-sty.svgtext/xml
.swfapplication/x-shockwave-flash.tdfapplication/x-tdf
.tg4application/x-tg4.tgaapplication/x-tga
.tifimage/tiff.tifapplication/x-tif
.tiffimage/tiff.tldtext/xml
.topdrawing/x-top.torrentapplication/x-bittorrent
.tsdtext/xml.txttext/plain
.uinapplication/x-icq.ulstext/iuls
.vcftext/x-vcard.vdaapplication/x-vda
.vdxapplication/vnd.visio.vmltext/xml
.vpgapplication/x-vpeg005.vsdapplication/vnd.visio
.vsdapplication/x-vsd.vssapplication/vnd.visio
.vstapplication/vnd.visio.vstapplication/x-vst
.vswapplication/vnd.visio.vsxapplication/vnd.visio
.vtxapplication/vnd.visio.vxmltext/xml
.wavaudio/wav.waxaudio/x-ms-wax
.wb1application/x-wb1.wb2application/x-wb2
.wb3application/x-wb3.wbmpimage/vnd.wap.wbmp
.wizapplication/msword.wk3application/x-wk3
.wk4application/x-wk4.wkqapplication/x-wkq
.wksapplication/x-wks.wmvideo/x-ms-wm
.wmaaudio/x-ms-wma.wmdapplication/x-ms-wmd
.wmfapplication/x-wmf.wmltext/vnd.wap.wml
.wmvvideo/x-ms-wmv.wmxvideo/x-ms-wmx
.wmzapplication/x-ms-wmz.wp6application/x-wp6
.wpdapplication/x-wpd.wpgapplication/x-wpg
.wplapplication/vnd.ms-wpl.wq1application/x-wq1
.wr1application/x-wr1.wriapplication/x-wri
.wrkapplication/x-wrk.wsapplication/x-ws
.ws2application/x-ws.wsctext/scriptlet
.wsdltext/xml.wvxvideo/x-ms-wvx
.xdpapplication/vnd.adobe.xdp.xdrtext/xml
.xfdapplication/vnd.adobe.xfd.xfdfapplication/vnd.adobe.xfdf
.xhtmltext/html.xlsapplication/vnd.ms-excel
.xlsapplication/x-xls.xlwapplication/x-xlw
.xmltext/xml.xplaudio/scpls
.xqtext/xml.xqltext/xml
.xquerytext/xml.xsdtext/xml
.xsltext/xml.xslttext/xml
.xwdapplication/x-xwd.x_bapplication/x-x_b
.sisapplication/vnd.symbian.install.sisxapplication/vnd.symbian.install
.x_tapplication/x-x_t.ipaapplication/vnd.iphone
.apkapplication/vnd.android.package-archive.xapapplication/x-silverlight-app

转载于:https://www.cnblogs.com/xinaixia/p/3962995.html

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值