We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
<label>
<label>节点代表在用户界面上的一个标题。
标题可以和特定的表单组件(form control)关联起来:
使用 for 属性例A
将表单组件放置在label节点内例B
form = string
用于将控件组元素与归属的表单关联起来。
for = string
用于指定和该label节点关联的表单组件。
属性值必须为同一文档中使用该label节点做标题的节点的id属性。
参考global attributes
使用for属性
<input type="checkbox" id="lost" name="lost"> <label for="lost">Lost</label>
将表单组件放置在label节点内
<label><input type="checkbox" name="lost"> Lost</label>
HTML5标准定义的<label>节点,请参考4.10.6 The label element.
There was an error while loading. Please reload this page.