I'm having some problems trying to get checkboxes and tags for outputting the correct HTML using CakePHP and Twitter Bootstrap.
The Bootstrap specification should be:
<div class="control-group"> <div class="controls"> <label class="checkbox"> <input type="checkbox"> Keep me logged in </label> </div> </div>
However, using the input values shown here (http://stackoverflow.com/a/9496242/1247225), this form form input:
echo $form->input('auto_login', array( 'type' => 'checkbox', 'label' => __('Keep me logged in', true)));
Outputs the following:
<div class="control-group"> <input type="hidden" name="data[User][auto_login]" id="UserAutoLogin_" value="0" /> <input type="checkbox" name="data[User][auto_login]" class="" value="1" id="UserAutoLogin" /> <div class="controls"> <label for="UserAutoLogin">Keep me logged in</label> </div> </div>
Any ideas how to set up this separate input so that it outputs the correct HTML bootstrap as above?
source share