C# 之 HttpResponse 類


      Response 對象,派生自HttpResponse 類,該類封裝來自 ASP.NET 操作的 HTTP 響應信息。存在於System.Web命名空間下。

      注:MIME(Multipurpose Internet Mail Extensions)多用途互聯網郵件擴展類型就是設定某種擴展名的文件用一種應用程序來打開的方式類型,當該擴展名文件被訪問的時候,瀏覽器會自動使用指定應用程序來打開。多用於指定一些客戶端自定義的文件名,以及一些媒體文件打開方式。 

      (一)構造函數:public HttpResponse(TextWriter writer)

名稱 用法 說明
Buffer Response.Buffer  = true

獲取或設置一個值,該值指示是否緩沖輸出並在處理完整個響應之后發送它。

(true or false)

BufferOutput Response.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 標頭。
Charset Response.Charset == "iso-8859-2" 獲取或設置輸出流的 HTTP 字符集。
ClientDisconnectedToken   獲取客戶端斷開時去除的 CancellationToken對象。
ContentEncoding Response.ContentEncoding.EncodingName 獲取或設置輸出流的 HTTP 字符集。
ContentType

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

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

獲取或設置輸出流的 HTTP MIME 類型,來區分不同種類的數據。
Cookies HttpCookie 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 事件。
EndFlush public 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 .tif image/tiff
.001 application/x-001 .301 application/x-301
.323 text/h323 .906 application/x-906
.907 drawing/907 .a11 application/x-a11
.acp audio/x-mei-aac .ai application/postscript
.aif audio/aiff .aifc audio/aiff
.aiff audio/aiff .anv application/x-anv
.asa text/asa .asf video/x-ms-asf
.asp text/asp .asx video/x-ms-asf
.au audio/basic .avi video/avi
.awf application/vnd.adobe.workflow .biz text/xml
.bmp application/x-bmp .bot application/x-bot
.c4t application/x-c4t .c90 application/x-c90
.cal application/x-cals .cat application/vnd.ms-pki.seccat
.cdf application/x-netcdf .cdr application/x-cdr
.cel application/x-cel .cer application/x-x509-ca-cert
.cg4 application/x-g4 .cgm application/x-cgm
.cit application/x-cit .class java/*
.cml text/xml .cmp application/x-cmp
.cmx application/x-cmx .cot application/x-cot
.crl application/pkix-crl .crt application/x-x509-ca-cert
.csi application/x-csi .css text/css
.cut application/x-cut .dbf application/x-dbf
.dbm application/x-dbm .dbx application/x-dbx
.dcd text/xml .dcx application/x-dcx
.der application/x-x509-ca-cert .dgn application/x-dgn
.dib application/x-dib .dll application/x-msdownload
.doc application/msword .dot application/msword
.drw application/x-drw .dtd text/xml
.dwf Model/vnd.dwf .dwf application/x-dwf
.dwg application/x-dwg .dxb application/x-dxb
.dxf application/x-dxf .edn application/vnd.adobe.edn
.emf application/x-emf .eml message/rfc822
.ent text/xml .epi application/x-epi
.eps application/x-ps .eps application/postscript
.etd application/x-ebx .exe application/x-msdownload
.fax image/fax .fdf application/vnd.fdf
.fif application/fractals .fo text/xml
.frm application/x-frm .g4 application/x-g4
.gbr application/x-gbr . application/x-
.gif image/gif .gl2 application/x-gl2
.gp4 application/x-gp4 .hgl application/x-hgl
.hmr application/x-hmr .hpg application/x-hpgl
.hpl application/x-hpl .hqx application/mac-binhex40
.hrf application/x-hrf .hta application/hta
.htc text/x-component .htm text/html
.html text/html .htt text/webviewhtml
.htx text/html .icb application/x-icb
.ico image/x-icon .ico application/x-ico
.iff application/x-iff .ig4 application/x-g4
.igs application/x-igs .iii application/x-iphone
.img application/x-img .ins application/x-internet-signup
.isp application/x-internet-signup .IVF video/x-ivf
.java java/* .jfif image/jpeg
.jpe image/jpeg .jpe application/x-jpe
.jpeg image/jpeg .jpg image/jpeg
.jpg application/x-jpg .js application/x-javascript
.jsp text/html .la1 audio/x-liquid-file
.lar application/x-laplayer-reg .latex application/x-latex
.lavs audio/x-liquid-secure .lbm application/x-lbm
.lmsff audio/x-la-lms .ls application/x-javascript
.ltr application/x-ltr .m1v video/x-mpeg
.m2v video/x-mpeg .m3u audio/mpegurl
.m4e video/mpeg4 .mac application/x-mac
.man application/x-troff-man .math text/xml
.mdb application/msaccess .mdb application/x-mdb
.mfp application/x-shockwave-flash .mht message/rfc822
.mhtml message/rfc822 .mi application/x-mi
.mid audio/mid .midi audio/mid
.mil application/x-mil .mml text/xml
.mnd audio/x-musicnet-download .mns audio/x-musicnet-stream
.mocha application/x-javascript .movie video/x-sgi-movie
.mp1 audio/mp1 .mp2 audio/mp2
.mp2v video/mpeg .mp3 audio/mp3
.mp4 video/mpeg4 .mpa video/x-mpg
.mpd application/vnd.ms-project .mpe video/x-mpeg
.mpeg video/mpg .mpg video/mpg
.mpga audio/rn-mpeg .mpp application/vnd.ms-project
.mps video/x-mpeg .mpt application/vnd.ms-project
.mpv video/mpg .mpv2 video/mpeg
.mpw application/vnd.ms-project .mpx application/vnd.ms-project
.mtx text/xml .mxp application/x-mmxp
.net image/pnetvue .nrf application/x-nrf
.nws message/rfc822 .odc text/x-ms-odc
.out application/x-out .p10 application/pkcs10
.p12 application/x-pkcs12 .p7b application/x-pkcs7-certificates
.p7c application/pkcs7-mime .p7m application/pkcs7-mime
.p7r application/x-pkcs7-certreqresp .p7s application/pkcs7-signature
.pc5 application/x-pc5 .pci application/x-pci
.pcl application/x-pcl .pcx application/x-pcx
.pdf application/pdf .pdf application/pdf
.pdx application/vnd.adobe.pdx .pfx application/x-pkcs12
.pgl application/x-pgl .pic application/x-pic
.pko application/vnd.ms-pki.pko .pl application/x-perl
.plg text/html .pls audio/scpls
.plt application/x-plt .png image/png
.png application/x-png .pot application/vnd.ms-powerpoint
.ppa application/vnd.ms-powerpoint .ppm application/x-ppm
.pps application/vnd.ms-powerpoint .ppt application/vnd.ms-powerpoint
.ppt application/x-ppt .pr application/x-pr
.prf application/pics-rules .prn application/x-prn
.prt application/x-prt .ps application/x-ps
.ps application/postscript .ptn application/x-ptn
.pwz application/vnd.ms-powerpoint .r3t text/vnd.rn-realtext3d
.ra audio/vnd.rn-realaudio .ram audio/x-pn-realaudio
.ras application/x-ras .rat application/rat-file
.rdf text/xml .rec application/vnd.rn-recording
.red application/x-red .rgb application/x-rgb
.rjs application/vnd.rn-realsystem-rjs .rjt application/vnd.rn-realsystem-rjt
.rlc application/x-rlc .rle application/x-rle
.rm application/vnd.rn-realmedia .rmf application/vnd.adobe.rmf
.rmi audio/mid .rmj application/vnd.rn-realsystem-rmj
.rmm audio/x-pn-realaudio .rmp application/vnd.rn-rn_music_package
.rms application/vnd.rn-realmedia-secure .rmvb application/vnd.rn-realmedia-vbr
.rmx application/vnd.rn-realsystem-rmx .rnx application/vnd.rn-realplayer
.rp image/vnd.rn-realpix .rpm audio/x-pn-realaudio-plugin
.rsml application/vnd.rn-rsml .rt text/vnd.rn-realtext
.rtf application/msword .rtf application/x-rtf
.rv video/vnd.rn-realvideo .sam application/x-sam
.sat application/x-sat .sdp application/sdp
.sdw application/x-sdw .sit application/x-stuffit
.slb application/x-slb .sld application/x-sld
.slk drawing/x-slk .smi application/smil
.smil application/smil .smk application/x-smk
.snd audio/basic .sol text/plain
.sor text/plain .spc application/x-pkcs7-certificates
.spl application/futuresplash .spp text/xml
.ssm application/streamingmedia .sst application/vnd.ms-pki.certstore
.stl application/vnd.ms-pki.stl .stm text/html
.sty application/x-sty .svg text/xml
.swf application/x-shockwave-flash .tdf application/x-tdf
.tg4 application/x-tg4 .tga application/x-tga
.tif image/tiff .tif application/x-tif
.tiff image/tiff .tld text/xml
.top drawing/x-top .torrent application/x-bittorrent
.tsd text/xml .txt text/plain
.uin application/x-icq .uls text/iuls
.vcf text/x-vcard .vda application/x-vda
.vdx application/vnd.visio .vml text/xml
.vpg application/x-vpeg005 .vsd application/vnd.visio
.vsd application/x-vsd .vss application/vnd.visio
.vst application/vnd.visio .vst application/x-vst
.vsw application/vnd.visio .vsx application/vnd.visio
.vtx application/vnd.visio .vxml text/xml
.wav audio/wav .wax audio/x-ms-wax
.wb1 application/x-wb1 .wb2 application/x-wb2
.wb3 application/x-wb3 .wbmp image/vnd.wap.wbmp
.wiz application/msword .wk3 application/x-wk3
.wk4 application/x-wk4 .wkq application/x-wkq
.wks application/x-wks .wm video/x-ms-wm
.wma audio/x-ms-wma .wmd application/x-ms-wmd
.wmf application/x-wmf .wml text/vnd.wap.wml
.wmv video/x-ms-wmv .wmx video/x-ms-wmx
.wmz application/x-ms-wmz .wp6 application/x-wp6
.wpd application/x-wpd .wpg application/x-wpg
.wpl application/vnd.ms-wpl .wq1 application/x-wq1
.wr1 application/x-wr1 .wri application/x-wri
.wrk application/x-wrk .ws application/x-ws
.ws2 application/x-ws .wsc text/scriptlet
.wsdl text/xml .wvx video/x-ms-wvx
.xdp application/vnd.adobe.xdp .xdr text/xml
.xfd application/vnd.adobe.xfd .xfdf application/vnd.adobe.xfdf
.xhtml text/html .xls application/vnd.ms-excel
.xls application/x-xls .xlw application/x-xlw
.xml text/xml .xpl audio/scpls
.xq text/xml .xql text/xml
.xquery text/xml .xsd text/xml
.xsl text/xml .xslt text/xml
.xwd application/x-xwd .x_b application/x-x_b
.sis application/vnd.symbian.install .sisx application/vnd.symbian.install
.x_t application/x-x_t .ipa application/vnd.iphone
.apk application/vnd.android.package-archive .xap application/x-silverlight-app


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM