Game Development Reference
In-Depth Information
Url
The url input type allows the user to enter a website url.
<input type="url"
placeholder="Enter your website address"
required
/>
Other valid attributes for the date input type include the following:
•
name
(value must be a string): Identifies a particular field by the string
value associated with the attribute.
•
disabled
(acceptable values include
disabled
,
""
, or empty): Speci-
fies that the element is disabled, and cannot receive control.
•
autocomplete
(acceptable values include
on
or
off
): Specifies wheth-
er the browser should store values entered by the user so inputting a
stored value in the future can be automatically completed by the browser
upon hint by user.
•
autofocus
(acceptable values include
autofocus
,
""
, or empty): Spe-
cifies to the browser that the element must receive focus immediately
after the document finishes loading.
•
maxlength
(value must be a non-negative integer): Specifies the max-
imum length of characters that the element can contain.
•
pattern
(value must be a valid regular expression pattern as defined by
ECMA 262): Specifies a pattern that the browser must validate the speci-
fied input against.
•
size
(value must be a positive integer): Specifies the maximum number
of characters displayed by the element although more characters may be
allowed to be entered.
•
placeholder
(value must be a string): Specifies a string to be shown to
the user as a hint as to what information the field expects. This string dis-
appears when data is entered into the field and is shown when the field
becomes empty.
•
multiple
(acceptable values include
multiple
,
""
, or empty): Speci-
fies that multiple values are allowed in this element.