1. 程式人生 > >HTML5學習筆記(<command>,<details>,<dialog>)

HTML5學習筆記(<command>,<details>,<dialog>)

detail win str strong data property html5 rop 支持

<command>
  目前,主流瀏覽器都不支持 <command> 標簽。
  註釋:只有 IE 9 支持 <command> 標簽,其他之前版本或者之後版本的 IE 瀏覽器不支持 <command> 標簽。
  想要了解的可以去菜鳥教程查看。

<details>
  目前,只有 Chrome 和 Safari 6 支持 <details> 標簽。
  <details>需要和<summary>一起使用,<summary>同樣是只有 Chrome 和 Safari 6 支持。
例子:

<details
> <summary>Copyright 1999-2011.</summary> <p> - by Refsnes Data. All Rights Reserved.</p> <p>All content and graphics on this web site are the property of the company Refsnes Data.</p> </details>

結果:

技術分享

open屬性(就是讓原本隱藏的內容顯示出來而已)
<details open>這樣既可。

open圖片:

技術分享

<dialog>
目前,只有 Chrome 和 Safari 6 支持 <dialog> 標簽。
<dialog> 標簽定義一個對話框、確認框或窗口。

例子:

<table border="1">
<tr>
<th>January <dialog open>This is an open dialog window</dialog></th>
<th>February</th>
<th>March</th>
</tr>
<tr>
<td>31</td> <td>28</td> <td>31</td> </tr> </table>

結果:

技術分享

它同樣擁有open屬性。

HTML5學習筆記(<command>,<details>,<dialog>)