<html>
<body>
<h1>input pattern 属性</h1>
<p>具有 URL 字段的表单,该字段必须以 http:// 或 https:// 开头,后跟至少一个字符:</p>
<form action="/demo/action_page.php">
<label for="website">首页:</label>
<input type="url" id="website" name="website" pattern="https?://.+" title="Include http://">
<input type="submit">
</form>
</body>
</html>