fmpq.com
源代码:
点击运行
<!DOCTYPE html> <html lang="en"> <head> <meta charset="utf-8"> <title>Bootstrap 版本2.0 表单错误实例</title> <meta name="description" content="Bootstrap Version2.0 form error example from fmpq.com."> <link href="/jscss/bootstrap/v3/bootstrap.css" rel="stylesheet"> </head> <body> <form class="form-horizontal"> <fieldset> <legend>表单验证错误,警告或成功</legend> <div class="control-group error"> <label class="control-label" for="inputError">输入错误</label> <div class="controls"> <input type="text" id="inputError"> <span class="help-inline">请纠正错误</span> </div> </div> <div class="control-group warning"> <label class="control-label" for="inputWarning">输入警告</label> <div class="controls"> <input type="text" id="inputWarning"> <span class="help-inline">出现一些错误</span> </div> </div> <div class="control-group success"> <label class="control-label" for="inputSuccess">成功输入</label> <div class="controls"> <input type="text" id="inputSuccess"> <span class="help-inline">成功输入</span> </div> </div> <div class="control-group success"> <label class="control-label" for="selectError">选择成功</label> <div class="controls"> <select id="selectError"> <option>1</option> <option>2</option> <option>3</option> <option>4</option> <option>5</option> </select> <span class="help-inline">选择成功</span> </div> </div> </fieldset> </form> </body> </html>
运行结果