Bootstrap Radio Examples

Stay Updated

Subscribe to Bootsnipp newsletter. (only important updates will be sent, your email is never shared or sold to anyone else)

Dan's Deals All Deals

Recent Comments

You dont have to use the HTML helper because as zholinho said, HTML helper create an extra input and that make the css do not work. Just delete your HTML and put a manual input, ypu can set the values as follow:<div class="checkbox checkbox-primary pull-right"> <input type="checkbox" name="NameOfAttribute" checked="@Model.AttributeBoolean" id="NameOfAttribute" value="@Model.AttributeBoolean.ToString().ToLower()" /> <label for="NameOfAttribute">Label Text</label> </div> To get if the element it´s cheked just use: var chk = $('input[name="NameOfAttribute"]:checked').length > 0This example was to detect a false or true, if you need the actual values use the val() function.Hope this could help to everyone with the same problema.
Bootstrap Checkboxes/Radios