--- id: 587d778c367417b2b2512aa9 challengeType: 0 videoUrl: 'https://scrimba.com/c/cmzMgtz' forumTopicId: 301025 localeTitle: 使用 HTML5 的 datatime 属性标准化时间 --- ## Description
继续日期主题。HTML5 还引入了time标签与datetime属性来标准化时间。time是一个行内标签,用于在页面中呈现日期或时间,而datetime属性保存了日期的有效格式,辅助设备可以访问这个值。通过标准化时间格式,即使时间在文本中是以非正式的或口语化的形式编写,辅助设备依然可以获取准确的时间和日期。 举个例子: <p>Master Camper Cat officiated the cage match between Goro and Scorpion <time datetime="2013-02-13">last Wednesday</time>, which ended in a draw.</p>
## Instructions
Camper Cat 的比武大会的时间确定了!请使用time标签包含文本 "Thursday, September 15<sup>th</sup>",并将datetime属性设置为 "2016-09-15"。
## Tests
```yml tests: - text: 'time标签应该包含文本"Thursday, September 15<sup>th</sup>"。' testString: assert(timeElement.length); - text: 'time标签应该有 1 个非空的datetime属性。' testString: assert(timeElement.length && $(timeElement).html().trim() === "Thursday, September 15th"); - text: 'datetime属性的值应该为 2016-09-15。' testString: assert(datetimeAttr && datetimeAttr.length); - text: '确保time标签是闭合的。' testString: assert(datetimeAttr === "2016-09-15"); ```
## Challenge Seed
```html

Tournaments

Mortal Kombat Tournament Survey Results

Thank you to everyone for responding to Master Camper Cat's survey. The best day to host the vaunted Mortal Kombat tournament is Thursday, September 15th. May the best ninja win!

Comments:

Posted by: Sub-Zero on

Johnny Cage better be there, I'll finish him!

Posted by: Doge on

Wow, much combat, so mortal.

Posted by: The Grim Reaper on

Looks like I'll be busy that day.

© 2018 Camper Cat
```
```html ```
## Solution
```html // solution required ```