HTML: The Markup Language

8. Forms attributes # T

This section defines attributes that are common to a number of forms elements.

autocomplete = "on" or "off" NEW#
Specifies whether the element represents an input control for which a UA is meant to store the value entered by the user (so that the UA can prefill the form later).
autofocus = "autofocus" or "" (empty string) or empty NEW#
Specifies that the element represents a control to which a UA is meant to give focus as soon as the document is loaded.
checked = "checked" or "" (empty string) or empty #
Specifies that the element represents a selected control.
disabled = "disabled" or "" (empty string) or empty #
Specifies that the element represents a disabled control.
form = IDREF NEW#
Identifies a form with which to associate the element.
formaction = URI NEW#
The form-submission action for the element.
formenctype = "application/x-www-form-urlencoded" or "multipart/form-data" or "text/plain" NEW#
A MIME type with which a UA is meant to associate this element for form submission.
formmethod = "get" or "post" or "put" or "delete" NEW#
The HTTP method with which a UA is meant to associate this element for form submission.
formnovalidate = "formnovalidate" or "" (empty string) or empty NEW#
Specifies that the element represents a control whose value is not meant to be validated during form submission.
formtarget = browsing-context name or keyword NEW#
A browsing context or keyword that represents the target of the control.
list = IDREF NEW#
Identifies a datalist with which to associate the element.
maxlength = positive integer #
The maximum allowed value length of the element.
multiple = "multiple" or "" (empty string) or empty NEW#
Specifies that the element allows multiple values.
name = string #
The name part of the name/value pair associated with this element for the purposes of form submission.
pattern = pattern NEW#
Specifies a regular expression against which a UA is meant to check the value of the control represented by its element.
placeholder = string NEW#
A short hint (one word or a short phrase) intended to aid the user when entering data into the control represented by its element.
readonly = "readonly" or "" (empty string) or empty #
Specifies that element represents a control whose value is not meant to be edited.
required = "required" or "" (empty string) or empty NEW#
Specifies that the element is a required part of form submission.
size = positive integer #
The number of options meant to be shown by the control represented by its element.
step = "any" or positive float NEW#
Specifies the value granularity of the element’s value.
step = "any" or positive integer NEW#
Specifies the value granularity of the element’s value.