UK[ˈleɪbl] 美[ˈleɪbl]
n. label; mark, symbol; [construction] molding on a door or window
vt. label on; call... ; List... as; [Chemistry] Use radioactive elements to trace (elements or atoms, etc.)
Third person singular: labels Plural: labels Present participle: labelling Past tense: labelled Past participle: labelled
html label label syntax
Function: Define annotations (markers) for input elements.
Note: The label element does not present any special effects to the user. However, it improves usability for mouse users. This control is triggered if you click on the text inside the label element. That is to say, when the user selects the label, the browser will automatically turn the focus to the form control related to the label.
Note: The "for" attribute can bind label to another element. Please set the value of the "for" attribute to the value of the id attribute of the relevant element.
html label label example
<html> <body> <p>请点击文本标记之一,就可以触发相关控件:</p> <form> <label for="male">Male</label> <input type="radio" name="sex" id="male" /> <br /> <label for="female">Female</label> <input type="radio" name="sex" id="female" /> </form> </body> </html>
Run Instance»
Click the "Run Instance" button to view the online instance
<html> <body> <p>点击文本,就可以触发相关控件:</p> <form> <label for="male">Male</label> <input type="text" id="male" /> <br /> <label for="female">Female</label> <input type="text" id="female" /> </form> </body> </html>
Run instance»
Click the "Run instance" button to view the online instance