November 2011
Intermediate to advanced
384 pages
13h 23m
English
You can use the URL input type, new in HTML5, to restrict input fields to values formatted like an absolute HTTP or HTTPS Internet address prefix. Supported web browsers will reject values that are not formatted with a proper prefix, but the address itself is not verified to determine whether it is real.
<input type='url' name='field' value='url'>
The type='url' attribute value activates the URL-specific input options of the user’s web browser, if supported. Additional input element attributes, such as name and value, have the same meaning and functionality common in HTML forms. If you assign value='url' to prepopulate the input field, the URL should be formatted with a proper prefix, such as http://www.mydomain.com ...
Read now
Unlock full access