-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathtest.html
More file actions
42 lines (38 loc) · 1.09 KB
/
Copy pathtest.html
File metadata and controls
42 lines (38 loc) · 1.09 KB
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
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Playground</title>
<script type="text/javascript" src="http://code.jquery.com/jquery-1.8.2.min.js"></script>
<script type="text/javascript" src="validator.min.js"></script>
<script type="text/javascript" src="validate.js"></script>
<script>
function validate(form) {
var pass = false;
$(form).formValidate({
ruleSet: ruleSet,
onPass: function() {
pass = true;
}
/*,
onFail: function(errors) {
$("#errors").empty();
for (var i = 0; i < errors.length; i++) {
$("#errors").append(errors[i]).append($("<br>"));
}
pass = false;
}*/
});
return pass;
}
</script>
</head>
<body>
<div id="errors"></div>
<form method="POST" onsubmit="return validate(this);">
<input name="summary" placeholder="summary"/>
<input id="personalEmail" placeholder="email"/>
<button type="submit">Validate</button>
</form>
</body>
</html>