HTTP 教程 转自 http://www.w3cschool.cc/http/http-tutorial.html
HTTP协议(HyperText Transfer Protocol,超文本传输协议)是因特网上应用最为广泛的一种网络传输协议,所有的WWW文件都必须遵守这个标准。
HTTP是一个基于TCP/IP通信协议来传递数据(HTML 文件, 图片文件, 查询结果等)。
内容列表
HTTP 简介
本章节介绍了HTTP协议。
HTTP 消息结构
本章节介绍了HTTP消息结构
HTTP 方法
本章节介绍了HTTP的方法,包括 GET, POST, HEAD 等。
HTTP 头信息
本章节介绍了HTTP的头信息
HTTP 状态码
本章节列出了所有HTTP的状态码。
HTTP 简介
HTTP协议是Hyper Text Transfer Protocol(超文本传输协议)的缩写,是用于从万维网(WWW:World Wide Web )服务器传输超文本到本地浏览器的传送协议。。
HTTP是一个基于TCP/IP通信协议来传递数据(HTML 文件, 图片文件, 查询结果等)。
HTTP 工作原理
HTTP协议工作于客户端-服务端架构为上。浏览器作为HTTP客户端通过URL向HTTP服务端即WEB服务器发送所有请求。
Web服务器有:Apache服务器,IIS服务器(Internet Information Services)等。
Web服务器根据接收到的请求后,向客户端发送响应信息。
HTTP默认端口号为80,但是你也可以改为8080或者其他端口。
HTTP三点注意事项:
- HTTP是无连接:无连接的含义是限制每次连接只处理一个请求。服务器处理完客户的请求,并收到客户的应答后,即断开连接。采用这种方式可以节省传输时间。
- HTTP是媒体独立的:这意味着,只要客户端和服务器知道如何处理的数据内容,任何类型的数据都可以通过HTTP发送。客户端以及服务器指定使用适合的MIME-type内容类型。
- HTTP是无状态:HTTP协议是无状态协议。无状态是指协议对于事务处理没有记忆能力。缺少状态意味着如果后续处理需要前面的信息,则它必须重传,这样可能导致每次连接传送的数据量增大。另一方面,在服务器不需要先前信息时它的应答就较快。
以下图表展示了HTTP协议通信流程:

HTTP 消息结构
HTTP是基于客户端/服务端(C/S)的架构模型,通过一个可靠的链接来交换信息,是一个无状态的请求/响应协议。
一个HTTP"客户端"是一个应用程序(Web浏览器或其他任何客户端),通过连接到服务器达到向服务器发送一个或多个HTTP的请求的目的。
一个HTTP"服务器"同样也是一个应用程序(通常是一个Web服务,如Apache Web服务器或IIS服务器等),通过接收客户端的请求并向客户端发送HTTP响应数据。
HTTP使用统一资源标识符(Uniform Resource Identifiers, URI)来传输数据和建立连接。
一旦建立连接后,数据消息就通过类似Internet邮件所使用的格式[RFC5322]和多用途Internet邮件扩展(MIME)[RFC2045]来传送。
客户端请求消息
客户端发送一个HTTP请求到服务器的请求消息包括以下格式:请求行(request line)、请求头部(header)、空行和请求数据4个部分组成,下图给出了请求报文的一般格式。

服务器响应消息
HTTP响应也由三个部分组成,分别是:状态行、消息报头、响应正文。

实例
下面实例是一点典型的使用GET来传递数据的实例:
客户端请求:
GET /hello.txt HTTP/1.1
User-Agent: curl/7.16.3 libcurl/7.16.3 OpenSSL/0.9.7l zlib/1.2.3
Host: www.example.com
Accept-Language: en, mi
服务端响应:
HTTP/1.1 200 OK
Date: Mon, 27 Jul 2009 12:28:53 GMT
Server: Apache
Last-Modified: Wed, 22 Jul 2009 19:15:56 GMT
ETag: "34aa387-d-1568eb00"
Accept-Ranges: bytes
Content-Length: 51
Vary: Accept-Encoding
Content-Type: text/plain
输出结果:
Hello World! My payload includes a trailing CRLF.
HTTP请求方法
根据HTTP标准,HTTP请求可以使用多种请求方法。
HTTP1.0定义了三种请求方法: GET, POST 和 HEAD方法。
HTTP1.1新增了五种请求方法:OPTIONS, PUT, DELETE, TRACE 和 CONNECT 方法。
| 序号 | 方法 | 描述 | 
|---|---|---|
| 1 | GET | 请求指定的页面信息,并返回实体主体。 | 
| 2 | HEAD | 类似于get请求,只不过返回的响应中没有具体的内容,用于获取报头 | 
| 3 | POST | 向指定资源提交数据进行处理请求(例如提交表单或者上传文件)。数据被包含在请求体中。POST请求可能会导致新的资源的建立和/或已有资源的修改。 | 
| 4 | PUT | 从客户端向服务器传送的数据取代指定的文档的内容。 | 
| 5 | DELETE | 请求服务器删除指定的页面。 | 
| 6 | CONNECT | HTTP/1.1协议中预留给能够将连接改为管道方式的代理服务器。 | 
| 7 | OPTIONS | 允许客户端查看服务器的性能。 | 
| 8 | TRACE | 回显服务器收到的请求,主要用于测试或诊断。 | 
HTTP请求头信息
HTTP请求头提供了关于请求,响应或者其他的发送实体的信息。在本章节中我们将具体来介绍HTTP请求头信息。
| 应答头 | 说明 | 
|---|---|
| Allow | 服务器支持哪些请求方法(如GET、POST等)。 | 
| Content-Encoding | 文档的编码(Encode)方法。只有在解码之后才可以得到Content-Type头指定的内容类型。利用gzip压缩文档能够显著地减少HTML文档的下载时间。Java的GZIPOutputStream可以很方便地进行gzip压缩,但只有Unix上的Netscape和Windows上的IE 4、IE 5才支持它。因此,Servlet应该通过查看Accept-Encoding头(即request.getHeader("Accept-Encoding"))检查浏览器是否支持gzip,为支持gzip的浏览器返回经gzip压缩的HTML页面,为其他浏览器返回普通页面。 | 
| Content-Length | 表示内容长度。只有当浏览器使用持久HTTP连接时才需要这个数据。如果你想要利用持久连接的优势,可以把输出文档写入ByteArrayOutputStram,完成后查看其大小,然后把该值放入Content-Length头,最后通过byteArrayStream.writeTo(response.getOutputStream()发送内容。 | 
| Content-Type | 表示后面的文档属于什么MIME类型。Servlet默认为text/plain,但通常需要显式地指定为text/html。由于经常要设置Content-Type,因此HttpServletResponse提供了一个专用的方法setContentType。 | 
| Date | 当前的GMT时间。你可以用setDateHeader来设置这个头以避免转换时间格式的麻烦。 | 
| Expires | 应该在什么时候认为文档已经过期,从而不再缓存它? | 
| Last-Modified | 文档的最后改动时间。客户可以通过If-Modified-Since请求头提供一个日期,该请求将被视为一个条件GET,只有改动时间迟于指定时间的文档才会返回,否则返回一个304(Not Modified)状态。Last-Modified也可用setDateHeader方法来设置。 | 
| Location | 表示客户应当到哪里去提取文档。Location通常不是直接设置的,而是通过HttpServletResponse的sendRedirect方法,该方法同时设置状态代码为302。 | 
| Refresh | 表示浏览器应该在多少时间之后刷新文档,以秒计。除了刷新当前文档之外,你还可以通过setHeader("Refresh", "5; URL=http://host/path")让浏览器读取指定的页面。 注意这种功能通常是通过设置HTML页面HEAD区的<META HTTP-EQUIV="Refresh" CONTENT="5;URL=http://host/path">实现,这是因为,自动刷新或重定向对于那些不能使用CGI或Servlet的HTML编写者十分重要。但是,对于Servlet来说,直接设置Refresh头更加方便。 注意Refresh的意义是"N秒之后刷新本页面或访问指定页面",而不是"每隔N秒刷新本页面或访问指定页面"。因此,连续刷新要求每次都发送一个Refresh头,而发送204状态代码则可以阻止浏览器继续刷新,不管是使用Refresh头还是<META HTTP-EQUIV="Refresh" ...>。 注意Refresh头不属于HTTP 1.1正式规范的一部分,而是一个扩展,但Netscape和IE都支持它。 | 
| Server | 服务器名字。Servlet一般不设置这个值,而是由Web服务器自己设置。 | 
| Set-Cookie | 设置和页面关联的Cookie。Servlet不应使用response.setHeader("Set-Cookie", ...),而是应使用HttpServletResponse提供的专用方法addCookie。参见下文有关Cookie设置的讨论。 | 
| WWW-Authenticate | 客户应该在Authorization头中提供什么类型的授权信息?在包含401(Unauthorized)状态行的应答中这个头是必需的。例如,response.setHeader("WWW-Authenticate", "BASIC realm=\"executives\"")。 注意Servlet一般不进行这方面的处理,而是让Web服务器的专门机制来控制受密码保护页面的访问(例如.htaccess)。 | 
HTTP状态码
当浏览者访问一个网页时,浏览者的浏览器会向网页所在服务器发出请求。当浏览器接收并显示网页前,此网页所在的服务器会返回一个包含HTTP状态码的信息头(server header)用以响应浏览器的请求。
HTTP状态码的英文为HTTP Status Code。
下面是常见的HTTP状态码:
- 200 - 请求成功
- 301 - 资源(网页等)被永久转移到其它URL
- 404 - 请求的资源(网页等)不存在
- 500 - 内部服务器错误
HTTP状态码分类
HTTP状态码由三个十进制数字组成,第一个十进制数字定义了状态码的类型,后两个数字没有分类的作用。HTTP状态码共分为5种类型:
| 分类 | 分类描述 | 
|---|---|
| 1** | 信息,服务器收到请求,需要请求者继续执行操作 | 
| 2** | 成功,操作被成功接收并处理 | 
| 3** | 重定向,需要进一步的操作以完成请求 | 
| 4** | 客户端错误,请求包含语法错误或无法完成请求 | 
| 5** | 服务器错误,服务器在处理请求的过程中发生了错误 | 
HTTP状态码列表:
| 状态码 | 状态码英文名称 | 中文描述 | 
|---|---|---|
| 100 | Continue | 继续。客户端应继续其请求 | 
| 101 | Switching Protocols | 切换协议。服务器根据客户端的请求切换协议。只能切换到更高级的协议,例如,切换到HTTP的新版本协议 | 
| 200 | OK | 请求成功。一般用于GET与POST请求 | 
| 201 | Created | 已创建。成功请求并创建了新的资源 | 
| 202 | Accepted | 已接受。已经接受请求,但未处理完成 | 
| 203 | Non-Authoritative Information | 非授权信息。请求成功。但返回的meta信息不在原始的服务器,而是一个副本 | 
| 204 | No Content | 无内容。服务器成功处理,但未返回内容。在未更新网页的情况下,可确保浏览器继续显示当前文档 | 
| 205 | Reset Content | 重置内容。服务器处理成功,用户终端(例如:浏览器)应重置文档视图。可通过此返回码清除浏览器的表单域 | 
| 206 | Partial Content | 部分内容。服务器成功处理了部分GET请求 | 
| 300 | Multiple Choices | 多种选择。请求的资源可包括多个位置,相应可返回一个资源特征与地址的列表用于用户终端(例如:浏览器)选择 | 
| 301 | Moved Permanently | 永久移动。请求的资源已被永久的移动到新URI,返回信息会包括新的URI,浏览器会自动定向到新URI。今后任何新的请求都应使用新的URI代替 | 
| 302 | Found | 临时移动。与301类似。但资源只是临时被移动。客户端应继续使用原有URI | 
| 303 | See Other | 查看其它地址。与301类似。使用GET和POST请求查看 | 
| 304 | Not Modified | 未修改。所请求的资源未修改,服务器返回此状态码时,不会返回任何资源。客户端通常会缓存访问过的资源,通过提供一个头信息指出客户端希望只返回在指定日期之后修改的资源 | 
| 305 | Use Proxy | 使用代理。所请求的资源必须通过代理访问 | 
| 306 | Unused | 已经被废弃的HTTP状态码 | 
| 307 | Temporary Redirect | 临时重定向。与302类似。使用GET请求重定向 | 
| 400 | Bad Request | 客户端请求的语法错误,服务器无法理解 | 
| 401 | Unauthorized | 请求要求用户的身份认证 | 
| 402 | Payment Required | 保留,将来使用 | 
| 403 | Forbidden | 服务器理解请求客户端的请求,但是拒绝执行此请求 | 
| 404 | Not Found | 服务器无法根据客户端的请求找到资源(网页)。通过此代码,网站设计人员可设置"您所请求的资源无法找到"的个性页面 | 
| 405 | Method Not Allowed | 客户端请求中的方法被禁止 | 
| 406 | Not Acceptable | 服务器无法根据客户端请求的内容特性完成请求 | 
| 407 | Proxy Authentication Required | 请求要求代理的身份认证,与401类似,但请求者应当使用代理进行授权 | 
| 408 | Request Time-out | 服务器等待客户端发送的请求时间过长,超时 | 
| 409 | Conflict | 服务器完成客户端的PUT请求是可能返回此代码,服务器处理请求时发生了冲突 | 
| 410 | Gone | 客户端请求的资源已经不存在。410不同于404,如果资源以前有现在被永久删除了可使用410代码,网站设计人员可通过301代码指定资源的新位置 | 
| 411 | Length Required | 服务器无法处理客户端发送的不带Content-Length的请求信息 | 
| 412 | Precondition Failed | 客户端请求信息的先决条件错误 | 
| 413 | Request Entity Too Large | 由于请求的实体过大,服务器无法处理,因此拒绝请求。为防止客户端的连续请求,服务器可能会关闭连接。如果只是服务器暂时无法处理,则会包含一个Retry-After的响应信息 | 
| 414 | Request-URI Too Large | 请求的URI过长(URI通常为网址),服务器无法处理 | 
| 415 | Unsupported Media Type | 服务器无法处理请求附带的媒体格式 | 
| 416 | Requested range not satisfiable | 客户端请求的范围无效 | 
| 417 | Expectation Failed | 服务器无法满足Expect的请求头信息 | 
| 500 | Internal Server Error | 服务器内部错误,无法完成请求 | 
| 501 | Not Implemented | 服务器不支持请求的功能,无法完成请求 | 
| 502 | Bad Gateway | 充当网关或代理的服务器,从远端服务器接收到了一个无效的请求 | 
| 503 | Service Unavailable | 由于超载或系统维护,服务器暂时的无法处理客户端的请求。延时的长度可包含在服务器的Retry-After头信息中 | 
| 504 | Gateway Time-out | 充当网关或代理的服务器,未及时从远端服务器获取请求 | 
| 505 | HTTP Version not supported | 服务器不支持请求的HTTP协议的版本,无法完成处理 | 
HTTP content-type
Content-Type,内容类型,一般是指网页中存在的Content-Type,用于定义网络文件的类型和网页的编码,决定浏览器将以什么形式、什么编码读取这个文件,这就是经常看到一些Asp网页点击的结果却是下载到的一个文件或一张图片的原因。
HTTP content-type 对照表
| 文件扩展名 | 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 | 
| application/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 | 
HTTP 教程 转自 http://www.w3cschool.cc/http/http-tutorial.html的更多相关文章
- SQLite 语法(http://www.w3cschool.cc/sqlite/sqlite-syntax.html)
		SQLite 语法 SQLite 是遵循一套独特的称为语法的规则和准则.本教程列出了所有基本的 SQLite 语法,向您提供了一个 SQLite 快速入门. 大小写敏感性 有个重要的点值得注意,SQL ... 
- SQLite Update 语句(http://www.w3cschool.cc/sqlite/sqlite-update.html)
		SQLite Update 语句 SQLite 的 UPDATE 查询用于修改表中已有的记录.可以使用带有 WHERE 子句的 UPDATE 查询来更新选定行,否则所有的行都会被更新. 语法 带有 W ... 
- SQLite Where 子句(http://www.w3cschool.cc/sqlite/sqlite-where-clause.html)
		SQLite Where 子句 SQLite的 WHERE 子句用于指定从一个表或多个表中获取数据的条件. 如果满足给定的条件,即为真(true)时,则从表中返回特定的值.您可以使用 WHERE 子句 ... 
- SQLite AND/OR 运算符(http://www.w3cschool.cc/sqlite/sqlite-and-or-clauses.html)
		SQLite AND/OR 运算符 SQLite 的 AND 和 OR 运算符用于编译多个条件来缩小在 SQLite 语句中所选的数据.这两个运算符被称为连接运算符. 这些运算符为同一个 SQLite ... 
- SQLite 运算符(http://www.w3cschool.cc/sqlite/sqlite-operators.html)
		SQLite 运算符 SQLite 运算符是什么? 运算符是一个保留字或字符,主要用于 SQLite 语句的 WHERE 子句中执行操作,如比较和算术运算. 运算符用于指定 SQLite 语句中的条件 ... 
- SQLite 表达式(http://www.w3cschool.cc/sqlite/sqlite-expressions.html)
		SQLite 表达式 表达式是一个或多个值.运算符和计算值的SQL函数的组合. SQL 表达式与公式类似,都写在查询语言中.您还可以使用特定的数据集来查询数据库. 语法 假设 SELECT 语句的基本 ... 
- SQLite Select 语句(http://www.w3cschool.cc/sqlite/sqlite-select.html)
		SQLite Select 语句 SQLite 的 SELECT 语句用于从 SQLite 数据库表中获取数据,以结果表的形式返回数据.这些结果表也被称为结果集. 语法 SQLite 的 SELECT ... 
- SQLite Insert 语句(http://www.w3cschool.cc/sqlite/sqlite-insert.html)
		SQLite Insert 语句 SQLite 的 INSERT INTO 语句用于向数据库的某个表中添加新的数据行. 语法 INSERT INTO 语句有两种基本语法,如下所示: INSERT IN ... 
- SQLite 删除表(http://www.w3cschool.cc/sqlite/sqlite-drop-table.html)
		SQLite 删除表 SQLite 的 DROP TABLE 语句用来删除表定义及其所有相关数据.索引.触发器.约束和该表的权限规范. 使用此命令时要特别注意,因为一旦一个表被删除,表中所有信息也将永 ... 
随机推荐
- 5.4.1 RegExp实例属性
			RegExp的每个实例都具有下列属性,通过这些属性可以取得有关模式的各种信息. 1.global:布尔值,表示是否设置了 g 标志. 2.ignoreCase:布尔值,表示 ... 
- 远程连接MySQL 不允许
			报错:1130-host ... is not allowed to connect to this MySql server 1. 改表法. 可能是你的帐号不允许从远程登陆,只能在localhost ... 
- PHP学习笔记7-JSON数据操作
			JSON,全称是JavaScript Object Notation.它是基于JavaScript编程语言ECMA-262 3rd Edition-December 1999标准的一种轻量级的数据交换 ... 
- [LeetCode]题解(python):115-Distinct Subsequences
			题目来源: https://leetcode.com/problems/distinct-subsequences/ 题意分析: 给定字符串S和T,判断S中可以组成多少个T,T是S的子串. 题目思路: ... 
- React使用笔记1-React的JSX和Style
			React使用笔记1-React的JSX和Style Date: 2015-11-27 20:56 Category: Web Tags: JavaScript Author: 刘理想 [toc] 1 ... 
- 磁盘IO子系统学习资料
			1.http://www.ibm.com/developerworks/cn/linux/l-cn-read/ (IBM read系统调用剖析) 2.http://lenky.info/arch ... 
- 解决用户 'IIS APPPOOL\Classic .NET AppPool' 登录失败
			解决用户 'IIS APPPOOL\Classic .NET AppPool' 登录失败 windows 7进入iis管理器 本地应用程序池 选中classic. net appPool 选择右侧的 ... 
- 转:js不同类型对象的比较规则
			Type(x) Type(y) Result type(x)==type(y) x===y otherwise... false null undefined true undefined null ... 
- Spinner样式大全
			Spinner样式大全 
- perl5 第五章 文件读写
			第五章 文件读写 by flamephoenix 一.打开.关闭文件二.读文件三.写文件四.判断文件状态五.命令行参数六.打开管道 一.打开.关闭文件 语法为open (filevar, file ... 
