Show Output
<!DOCTYPE html> <html lang="en"> <head> <meta charset="utf-8"> <meta http-equiv="X-UA-Compatible" content="IE=edge"> <meta name="viewport" content="width=device-width, initial-scale=1"> <title>Example of Bootstrap 3 Forms with Feedback Icons</title> <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css"> <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.12.4/jquery.min.js"></script> <script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js"></script> <style type="text/css"> .bs-example{ margin: 20px; } </style> </head> <body> <div class="bs-example"> <form class="form-horizontal"> <div class="form-group has-success has-feedback"> <label class="col-xs-2 control-label" for="inputSuccess">Username</label> <div class="col-xs-10"> <input type="text" id="inputSuccess" class="form-control" placeholder="Input with success"> <span class="glyphicon glyphicon-ok form-control-feedback"></span> <span class="help-block">Username is available</span> </div> </div> <div class="form-group has-warning has-feedback"> <label class="col-xs-2 control-label" for="inputWarning">Password</label> <div class="col-xs-10"> <input type="password" id="inputWarning" class="form-control" placeholder="Input with warning"> <span class="glyphicon glyphicon-warning-sign form-control-feedback"></span> <span class="help-block">Password strength: Weak</span> </div> </div> <div class="form-group has-error has-feedback"> <label class="col-xs-2 control-label" for="inputError">Email</label> <div class="col-xs-10"> <input type="email" id="inputError" class="form-control" placeholder="Input with error"> <span class="glyphicon glyphicon-remove form-control-feedback"></span> <span class="help-block">Please enter a valid email address</span> </div> </div> </form> </div> </body> </html>