代码如下:
<div class="container"> <div class="row"><!-- <form action="#" class="form-inline">--> <form action="#" class="form-horizontal"> <div class="form-group"><!--在有form-inline属性时可以省略掉。--> <label for="userName" class="col-lg-1 control-label">用户名:</label> <div class="col-lg-6"> <input type="text" id="userName" class="form-control"/> </div> </div> <div class="form-group-lg"><!--form-group后再加上lg,可以改变文本框的高度--> <label for="passWord" class="col-lg-1 control-label">密 码:</label> <div class="col-lg-6"> <input type="text" id="password" class="form-control"/> </div> </div> <div class="form-group"> <div class="col-lg-6 col-lg-offset-1"> <div class="checkbox"> <label class="checkbox-inline"><input type="checkbox"/>记住名字</label> <label class="checkbox-inline"><input type="checkbox"/>记住密码</label> <label class="checkbox-inline"><input type="checkbox"/>自动登录</label> </div> <div class="radio"> <label><input type="radio"/>自动登录</label> </div> </div> </div> <div class="form-group"> <div class="col-lg-1 col-lg-offset-1"> <input type="button" value="登录" class="btn"/> </div> </div> </form> </div> </div>新闻热点
疑难解答