HTML <details> 標(biāo)簽
定義和用法
<details> 標(biāo)簽用于描述文檔或文檔某個部分的細(xì)節(jié)。 ( 推薦學(xué)習(xí):html教程 )
瀏覽器支持
目前只有 Chrome 支持 <details> 標(biāo)簽。
HTML 4.01 與 HTML 5 之間的差異
<details> 標(biāo)簽是 HTML 5 中的新標(biāo)簽。
提示
提示:與 <summary> 標(biāo)簽 配合使用可以為 details 定義標(biāo)題。標(biāo)題是可見的,用戶點擊標(biāo)題時,會顯示出 details。
實例
關(guān)于文檔的細(xì)節(jié):
<!DOCTYPE HTML> <html> <body> <details> <summary>Copyright 2011.</summary> <p>All pages and graphics on this web site are the property of W3School.</p> </details> </body> </html>
效果圖: