使用Bootstrap默认选择单选按钮

时间:2013-09-12 03:49:23

标签: html css twitter-bootstrap

在不使用jquery的情况下,在twitter的bootstrap中预选单选按钮。

1 个答案:

答案 0 :(得分:2)

<div class="btn-group" data-toggle="buttons">
     <label class="btn btn-primary active">
        <input type="radio" name="options" id="athletebutton" value="1" checked> Athlete  </label>

      <label class="btn btn-primary">
        <input type="radio" name="options" id="coachbutton"> Coach </label>
  </div>

使用active

标记标签类

查看截图&amp;视频:

视频:http://d.pr/v/b3Gm

截图:

enter image description here

相关问题