diff options
author | Peter Bengtsson <mail@peterbe.com> | 2020-12-08 14:40:17 -0500 |
---|---|---|
committer | Peter Bengtsson <mail@peterbe.com> | 2020-12-08 14:40:17 -0500 |
commit | 33058f2b292b3a581333bdfb21b8f671898c5060 (patch) | |
tree | 51c3e392513ec574331b2d3f85c394445ea803c6 /files/zh-cn/web/http/headers/date | |
parent | 8b66d724f7caf0157093fb09cfec8fbd0c6ad50a (diff) | |
download | translated-content-33058f2b292b3a581333bdfb21b8f671898c5060.tar.gz translated-content-33058f2b292b3a581333bdfb21b8f671898c5060.tar.bz2 translated-content-33058f2b292b3a581333bdfb21b8f671898c5060.zip |
initial commit
Diffstat (limited to 'files/zh-cn/web/http/headers/date')
-rw-r--r-- | files/zh-cn/web/http/headers/date/index.html | 86 |
1 files changed, 86 insertions, 0 deletions
diff --git a/files/zh-cn/web/http/headers/date/index.html b/files/zh-cn/web/http/headers/date/index.html new file mode 100644 index 0000000000..7160a889e7 --- /dev/null +++ b/files/zh-cn/web/http/headers/date/index.html @@ -0,0 +1,86 @@ +--- +title: Date +slug: Web/HTTP/Headers/Date +tags: + - 日期 + - 格林尼治标准时间 + - 通用首部 + - 首部 +translation_of: Web/HTTP/Headers/Date +--- +<div>{{HTTPSidebar}}</div> + +<p><strong><code>Date </code></strong>是一个通用首部,其中包含了报文创建的日期和时间。</p> + +<table class="properties"> + <tbody> + <tr> + <th scope="row">Header type</th> + <td>{{Glossary("General header")}}</td> + </tr> + <tr> + <th scope="row">{{Glossary("Forbidden header name")}}</th> + <td>yes</td> + </tr> + </tbody> +</table> + +<h2 id="语法">语法</h2> + +<pre class="syntaxbox">Date: <day-name>, <day> <month> <year> <hour>:<minute>:<second> GMT +</pre> + +<h2 id="指令">指令</h2> + +<dl> + <dt><day-name></dt> + <dd>"Mon", "Tue", "Wed", "Thu", "Fri", "Sat", 或 "Sun" 之一 (区分大小写)。</dd> + <dt><day></dt> + <dd>2位数字表示天数,例如, "04" 或 "23"。</dd> + <dt><month></dt> + <dd>"Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec" 之一(区分大小写)。</dd> + <dt><year></dt> + <dd>4位数字表示年份,例如, "1990" 或 "2016"。</dd> + <dt><hour></dt> + <dd>2位数字表示小时数,例如, "09" 或 "23"。</dd> + <dt><minute></dt> + <dd>2位数字表示分钟数,例如, "04" 或 "59"。</dd> + <dt><second></dt> + <dd>2位数字表示秒数,例如, "04" 或 "59"。</dd> + <dt>GMT</dt> + <dd> + <p>格林尼治标准时间。 在HTTP协议中,时间都是用格林尼治标准时间来表示的,而不是本地时间。</p> + </dd> +</dl> + +<h2 id="示例">示例</h2> + +<pre>Date: Wed, 21 Oct 2015 07:28:00 GMT +</pre> + +<h2 id="规范">规范</h2> + +<table class="standard-table"> + <tbody> + <tr> + <th scope="col">Specification</th> + <th scope="col">Title</th> + </tr> + <tr> + <td>{{RFC("7231", "Date", "7.1.1.2")}}</td> + <td>Hypertext Transfer Protocol (HTTP/1.1): Semantics and Content</td> + </tr> + </tbody> +</table> + +<h2 id="浏览器兼容性">浏览器兼容性</h2> + +<p class="hidden">The compatibility table in this page is generated from structured data. If you'd like to contribute to the data, please check out <a href="https://github.com/mdn/browser-compat-data">https://github.com/mdn/browser-compat-data</a> and send us a pull request.</p> + +<p>{{Compat("http.headers.Date")}}</p> + +<h2 id="相关内容">相关内容</h2> + +<ul> + <li>{{HTTPHeader("Age")}}</li> +</ul> |