是的,<dd> 包含<ul> 是有效的。根据HTML Spec,<dd> 元素应该包含flow content。无序列表被视为流内容。
但是,如果您的示例中的每个项目都是后续 <dt> 术语的替代描述,则它们不应在无序列表中进行标记,而应使用系列进行标记<dd> 个元素。
例如,以下是有效的 HTML,但 语义不正确——因为它暗示整个列表是对该术语的单一描述。
<dl>
<dt>Firefox</dt>
<dd>
<ul>
<li>A free, open source, cross-platform, graphical web browser developed by the Mozilla Corporation and hundreds of volunteers.</li>
<li>The Red Panda also known as the Lesser Panda, Wah, Bear Cat or Firefox, is a mostly herbivorous mammal, slightly larger than a domestic cat (60 cm long).</li>
</ul>
</dd>
</dl>
标记此内容的有效语义正确方法是:
<dl>
<dt>Firefox</dt>
<dd>A free, open source, cross-platform, graphical web browser developed by the Mozilla Corporation and hundreds of volunteers.</dd>
<dd>The Red Panda also known as the Lesser Panda, Wah, Bear Cat or Firefox, is a mostly herbivorous mammal, slightly larger than a domestic cat (60 cm long).</dd>
</dl>