/
novalidate.html
38 lines (35 loc) · 1.05 KB
/
novalidate.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset=utf-8 />
<title>formnovalidate</title>
<style>
body, input, textarea {
font-family: "helvetica", arial, helvetica;
}
label {
display: block;
float: left;
clear: left;
text-align: right;
width: 100px;
margin-right: 10px;
}
div { padding: 10px; }
fieldset { border: 1px solid #ccc; margin-bottom: 20px; }
</style>
</head>
<body>
<form>
<fieldset>
<legend>Some bits about you</legend>
<div><label for="email">Email:</label> <input id="email" name="email" type="email" required /></div>
<div><label for="url">Homepage:</label><input id="url" type="url" name="url" /></div>
<div><textarea name="comment" cols="100" rows="5" required></textarea></div>
<div><input type="submit" value="save current state" formnovalidate /> <em>won't validate the form</em></div>
</fieldset>
<p>Now imagine there's lots more to this form that you'd want to save as you go along...and then finally: submit</p>
<div><input type="submit" /> <em>I will validate the form</em></div>
</form>
</body>
</html>