CREATE A URL INPUT TYPE

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 ...

Get HTML5: Your visual blueprint™ for designing rich web pages and applications now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.