Form Element Attributes
-
novalidate
Overrides the default behavior of a form having to be validated when it is submitted.
-
method
The HTTP method that is used to submit the form:
- post
- get
- dialog
-
action
The URL that processes the submitted form.
Form Elements
fieldset
Used as a container for a group of inputs and their labels.
legend
A caption for the fieldset that it belongs to.
Label Element
A caption for the input that it is associated with.
In order to connect a label to its input, the value of the label's for attribute must match the input's id. Clicking/touching the label will trigger the :focus state of the input. Screen readers will also read the label out loud when the user is focused on the control.
Form Elements Summary
Forms are used to submit information that is processed somewhere else on the internet. Making controls that are associated with a label allows users to provide the necessary information to be sent.