慕粉3771367
2016-09-12 15:49
<!doctype html> <html> <head> <meta charset="UTF-8"> <title>表单控件状态——禁用状态</title> <link rel="stylesheet" href="//netdna.bootstrapcdn.com/bootstrap/3.1.1/css/bootstrap.min.css"> </head> <body> <h3>示例1</h3> <form role="form"> <div> <div> <input class="form-control input-lg" type="text" placeholder="不是焦点状态下效果"> </div> <div> <input class="form-control input-lg" id="disabledInput" type="text" placeholder="表单已被禁用,不可输入" disabled> </div> </div> </form> <br> <br> <br> <h3>示例2</h3> <form role="form"> <fieldset disabled> <div> <label for="disabledTextInput">禁用的输入框</label> <input type="text" id="disabledTextInput" placeholder="禁止输入"> </div> <div> <label for="disabledSelect">禁用的下拉框</label> <select id="disabledSelect"> <option>不可选择</option> </select> </div> <div> <label> <input type="checkbox"> 无法选择 </label> </div> <button type="submit" class="btn btn-primary">提交</button> </fieldset> </form> <br> <br> <br> <h3>示例3</h3> <form role="form"> <fieldset disabled> <legend><input type="text" placeholder="显然我颜色变灰了,但是我没被禁用,不信?单击试一下" /></legend> <div> <label for="disabledTextInput">禁用的输入框</label> <input type="text" id="disabledTextInput" placeholder="禁止输入"> </div> <div> <label for="disabledSelect">禁用的下拉框</label> <select id="disabledSelect"> <option>不可选择</option> </select> </div> <div> <label> <input type="checkbox"> 无法选择 </label> </div> <button type="submit" class="btn btn-primary">提交</button> </fieldset> </form> </body> </html>
换个编译器试一试
可以输入啊你的我试了
玩转Bootstrap(基础)
314544 学习 · 2275 问题
相似问题