码迷,mamicode.com
首页 > 其他好文 > 详细

Bootstrap中表单控件状态(验证状态)

时间:2017-08-03 13:47:35      阅读:120      评论:0      收藏:0      [点我收藏+]

标签:head   feedback   error   ref   tps   war   www   hicon   styles   

 

Bootstrap 表单 http://www.runoob.com/try/try2.php?filename=bootstrap3-form-controlstate (这链接里有简介)

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Document</title>
<link rel="stylesheet" href="http://cdn.bootcss.com/bootstrap/3.3.0/css/bootstrap.min.css" >
</head>
<script src="https://cdn.bootcss.com/jquery/3.2.1/jquery.min.js"></script>
<script src="http://cdn.bootcss.com/bootstrap/3.3.0/js/bootstrap.min.js"></script>

<style>
    .right_20{right:20px;}
</style>

<body>
    <div class="width90_">
        <form class="form-horizontal bs-example bs-example-form">
            <div class="form-group form-group-sm has-success">
                <label class="fontSize12 col-sm-4 control-label" for="old_pwd">
                    <span style = ‘color:red;‘></span>成功
                </label>
                <div class="col-sm-6">
                    <input maxLength = ‘50‘ class="form-control" type="text" id="old_pwd" placeholder="" >
                    <span class="glyphicon glyphicon-ok form-control-feedback right_20"></span>
                </div>
            </div>
            <div class="form-group form-group-sm has-warning">
                <label class="fontSize12 col-sm-4 control-label" for="new_pwd">
                    <span style = ‘color:red;‘></span>警告
                </label>
                <div class="col-sm-6">
                    <input maxLength = ‘50‘ class="form-control" type="text" id="new_pwd" placeholder="" >
                    <span class="glyphicon glyphicon-warning-sign form-control-feedback right_20"></span>
                </div>
            </div>
            
            <div class="form-group form-group-sm has-error">
                <label class="fontSize12 col-sm-4 control-label" for="re_new_pwd">
                    <span style = ‘color:red;‘></span>错误
                </label>
                <div class="col-sm-6">
                    <input class="form-control" type="text" id="re_new_pwd" placeholder="">
                    <span class="glyphicon glyphicon-remove form-control-feedback right_20"></span>
                </div>
            </div>
        </form>
        
    </div>
</body>
</html>

 

Bootstrap中表单控件状态(验证状态)

标签:head   feedback   error   ref   tps   war   www   hicon   styles   

原文地址:http://www.cnblogs.com/aiyr/p/7278914.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!