codelevel
asked on
form validation
i have a form, i want to use built-in validation plugin to validate the form fields with error message on top of each field.
please suggest.
please suggest.
<!DOCTYPE html>
<html lang="en">
<head>
<title>Bootstrap Example</title>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="http://maxcdn.bootstrapcdn.com/bootstrap/3.3.5/css/bootstrap.min.css">
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.3/jquery.min.js"></script>
<script src="http://maxcdn.bootstrapcdn.com/bootstrap/3.3.5/js/bootstrap.min.js"></script>
</head>
<body>
<div class="container">
<form class="form-horizontal" role="form">
<div class="form-group">
<label class="col-sm-2 control-label">Email </label>
<div class="col-sm-10">
<input id="email" type="password" name="email">
</div>
</div>
<div class="form-group">
<label class="col-sm-2 control-label">Password </label>
<div class="col-sm-10">
<input id="password" type="password" name="password">
</div>
</div>
<div class="row">
<div class="col-sm-2"> </div>
<div class="col-sm-10">
<input type="checkbox" id="remember">
<label for="remember">Remember me</label>
</div>
</div>
<div class="row">
<div class="col-sm-2"> </div>
<div class="col-sm-10">
<input type="submit" class="btn btn-default" value="go">
</div>
</div>
</form>
</div>
</body>
</html>
ASKER CERTIFIED SOLUTION
membership
Create a free account to see this answer
Signing up is free and takes 30 seconds. No credit card required.