Set initial value for bootstrap checkbox button
See Bootstrap's bleeding-edge docs:
Pre-checked options need
.active
For pre-checked options, you must add the
.active
class to the<input>
's<label>
yourself.
Looks like you are missing the 'active' class in the second label. Is this what you were looking for?
<div class="btn-group" data-toggle="buttons">
<label class="btn btn-default">
<input type="checkbox">Hello 1
</label>
<label class="btn btn-default active">
<input type="checkbox" checked="checked">Hello 2
</label>
<label class="btn btn-default">
<input type="checkbox">Hello 3
</label>
</div>