Introduction of This article:HTML <checkbox> Label usage resolution and how to set the default check state of the CheckBox checkbox (compiled by www.169it.com) The CheckBox CheckBox object represents a selection box in an HTML form. Property Properties for CheckBox checkbox object in HTML Description a ...
HTML <checkbox> Label usage resolution and how to Set checkbox checkbox default Check (collected by www.169it.com)
The check box CheckBox object in HTML represents a selection box in an HTML form.
Properties for CheckBox checkbox objects in HTML
Attribute description
AccessKey Sets or returns the shortcut key to access the checkbox.
ALT Sets or returns the alternate text that is displayed when a checkbox is not supported.
Checked sets or returns whether a checkbox should be selected.
Defaultchecked returns the default value for the Checked property.
Disabled sets or returns whether a checkbox should be disabled.
Form returns a reference to the form that contains the checkbox.
ID to set or return the ID of the checkbox.
Name Sets or returns the names of the checkbox.
TabIndex Sets or returns the tab control order for the checkbox.
Type returns the form element types of the checkbox.
value to set or return values of the checkbox's Value property
Standard properties for checkbox checkbox in HTML
Attribute description
ClassName Sets or returns the class attribute of an element.
Dir Sets or returns the orientation of the text.
Lang Sets or returns the language code for the element.
Title Sets or returns the title property of an element.
Methods for CheckBox checkbox objects in HTML
Method description
Blur () removes the focus from the checkbox.
Click () to simulate a mouse click in a checkbox.
Focus () focuses on the checkbox.
check box checkbox in HTML Set default check code
1 |
< input name = "checkbox" type = "checkbox" value = "checkbox" checked = "Checked"/> |
Note: checked= "Checked" indicates the default check state.
check box checkbox in HTML check box use example
1 2 3 4 5 6 7 |
< form action = "" method = ' Get ' > your favorite water Fruit. < br />< br /> < label >< input name = "Fruit" type = "checkbox" |