PageRenderTime 6ms CodeModel.GetById 2ms app.highlight 1ms RepoModel.GetById 1ms app.codeStats 0ms

/lib/jquery-validate/demo/example.html

#
HTML | 52 lines | 45 code | 7 blank | 0 comment | 0 complexity | 8cf6763d3480a49a31f7889515fa56aa MD5 | raw file
 1<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
 2<html xmlns="http://www.w3.org/1999/xhtml">
 3<head>
 4<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" />
 5<title>jQuery validation plug-in - comment form example</title>
 6
 7<link rel="stylesheet" type="text/css" media="screen" href="css/screen.css" />
 8
 9<script src="../lib/jquery.js" type="text/javascript"></script>
10<script src="../jquery.validate.js" type="text/javascript"></script>
11
12<script type="text/javascript">
13$(document).ready(function() {
14	$("#commentForm").validate();
15});
16</script>
17
18<style type="text/css">
19#commentForm { width: 500px; }
20#commentForm label { width: 250px; }
21#commentForm label.error, #commentForm input.submit { margin-left: 253px; }
22</style>
23
24</head>
25<body>
26
27<form class="cmxform" id="commentForm" method="post" action="">
28	<fieldset>
29		<legend>Please provide your name, email address (won't be published) and a comment</legend>
30		<p>
31			<label for="cname">Name (required, at least 2 characters)</label>
32			<input id="cname" name="name" class="required" minlength="2" />
33		<p>
34			<label for="cemail">E-Mail (required)</label>
35			<input id="cemail" name="email" class="required email" />
36		</p>
37		<p>
38			<label for="curl">URL (optional)</label>
39			<input id="curl" name="url" class="url" value="" />
40		</p>
41		<p>
42			<label for="ccomment">Your comment (required)</label>
43			<textarea id="ccomment" name="comment" class="required"></textarea>
44		</p>
45		<p>
46			<input class="submit" type="submit" value="Submit"/>
47		</p>
48	</fieldset>
49</form>
50
51</body>
52</html>