<aside> 元素表示一个和其余页面内容几乎无关的部分,被认为是独立于该内容的一部分并且可以被单独的拆分出来而不会使整体受影响。其通常表现为侧边栏或者嵌入内容。他们通常包含在工具条,例如来自词汇表的定义。也可能有其他类型的信息,例如相关的广告、笔者的传记、web 应用程序、个人资料信息,或在博客上的相关链接。
注意:
- 不要将 <aside> 元素去标记括号内的文本,因为这种类型的文本(即括号内的文本)被认为是其内容流的一部分。
- 内容类别 Flow content, sectioning content, palpable content.
- 允许内容Flow content.
- 标签省略不允许,开始标签和结束标签都不能省略。
- 允许的父元素 所有接受 flow content 的元素。 注意
<aside>元素不能成为<address>元素的子元素 - DOM 接口
HTMLElement
属性
只具有全局属性.
示例
<article>
<p>
The Disney movie <em>The Little Mermaid</em> was
first released to theatres in 1989.
</p>
<aside>
The movie earned $87 million during its initial release.
</aside>
<p>
More info about the movie...
</p>
</article>
标准
| Specification | Status | Comment |
|---|---|---|
| WHATWG HTML Living Standard <aside> |
Living Standard | |
| HTML5 <aside> |
Recommendation |
浏览器兼容
| Feature | Chrome | Firefox (Gecko) | Internet Explorer | Opera | Safari |
|---|---|---|---|---|---|
| Basic support | 5 | 4.0 (2.0) | 9.0 | 11.10 | 4.1 |
| Feature | Android | Firefox Mobile (Gecko) | IE Mobile | Opera Mobile | Safari Mobile |
|---|---|---|---|---|---|
| Basic support | 2.2 | 4.0 (2.0) | 9.0 | 11.0 | 5.0 (iOS 4.2) |
查看类似的元素
- Others section-related elements:
<body>,<article>,<section>,<nav>,<h1>,<h2>,<h3>,<h4>,<h5>,<h6>,<hgroup>,<header>,<footer>,<address>; - Sections and outlines of an HTML5 document.