forked from mattjburrows/jquery-validation
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
68 lines (68 loc) · 2.54 KB
/
index.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
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>Essence Digital - jQuery Validation plugin</title>
<link rel="stylesheet" href="css/essence-validation.css" />
</head>
<body>
<form action="#" method="post" id="validator">
<fieldset>
<legend>Essence Digital jQuery form validation</legend>
<div>
<label for="first-name">First name:</label>
<input type="text" name="first-name" id="first-name" class="required" />
</div>
<div>
<label for="last-name">Last name:</label>
<input type="text" name="last-name" id="last-name" class="required" />
</div>
<div>
<label for="email-address">Email address:</label>
<input type="email" name="email-address" id="email-address" class="required" />
</div>
<div>
<label for="telephone">Telephone:</label>
<input type="tel" name="telephone" id="telephone" class="required" />
</div>
<div>
<label for="message">Message:</label>
<textarea name="message" id="message" cols="30" rows="10" class="required"></textarea>
</div>
<div>
<label for="message">Select box:</label>
<select name="select-box" id="select-box" class="required" data-defaulterror="Please make a selection">
<option value="">-- Select --</option>
<option value="1">yes</option>
<option value="0">no</option>
</select>
</div>
<div>
<label for="yes"><input type="radio" name="radiobuttons" id="yes" class="required" data-defaulterror="Please select at least one"> Yes</label>
<label for="no"><input type="radio" id="no" name="radiobuttons"> No</label>
<label for="maybe"><input type="radio" id="maybe" name="radiobuttons"> Maybe</label>
</div>
<div>
<label for="one"><input type="checkbox" name="checkboxes[]" id="one" class="required" data-defaulterror="Please select at least one"> One</label>
<label for="two"><input type="checkbox" name="checkboxes[]" id="two"> Two</label>
<label for="three"><input type="checkbox" name="checkboxes[]" id="three"> Three</label>
</div>
<div>
<input type="submit" value="Submit" />
</div>
</fieldset>
</form>
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js"></script>
<script>window.jQuery || document.write( '<script src="js/vendors/jquery-1.9.0.min.js"><\/script>' );</script>
<script src="js/jquery-essence-validation.js"></script>
<script>
(function($) {
$(document).on({
'ready': function () {
$('#validator').essenceValidation();
}
});
})(jQuery);
</script>
</body>
</html>