首页 > HTML/XHTML, Web标准 > 标签约束(Element Prohibitions)

标签约束(Element Prohibitions)

下列标签定义了一些约束条件指明其可以包含哪些标签作为子元素(参见SGML Exclusions)。此约束适用于所有的层次的嵌套,即适用所有的后代元素。

a标签:不能包含其他a标签

pre标签:不能包含imgobjectbigsmallsubsup标签

button标签:不能包含inputselecttextarealabelbuttonformfieldsetiframeisindex标签

label标签:不能包含其他label标签

form标签:不能包含其他form标签

此文系翻译之W3CElement Prohibitions片段,原文如下:

The following elements have prohibitions on which elements they can contain (see SGML Exclusions). This prohibition applies to all depths of nesting, i.e. it contains all the descendant elements.

a
must not contain other a elements.
pre
must not contain the img, object, big, small, sub, or sup elements.
button
must not contain the input, select, textarea, label, button, form, fieldset, iframe or isindex elements.
label
must not contain other label elements.
form
must not contain other form elements.

  1. 还没有评论。
  1. No trackbacks yet.

发表评论

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / 更改 )

Twitter picture

You are commenting using your Twitter account. Log Out / 更改 )

Facebook photo

You are commenting using your Facebook account. Log Out / 更改 )

Connecting to %s

加关注

Get every new post delivered to your Inbox.