Reputation: 604
When the form helper creates checkboxes, they stack vertically. I want them in a row horizontally to save space. How do I do this?
Upvotes: 1
Views: 2887
Reputation: 3583
Try doing each checkbox individually.
<?php
echo $this->Form->checkbox('somegroup', array('value' => 'foo', 'style' => 'float: left; display: inline'));
echo $this->Form->checkbox('somegroup', array('value' => 'bar', 'style' => 'float: left; display: inline'));
?>
Upvotes: 2