Skip to content

Commit

Permalink
Hotfix for required attribute
Browse files Browse the repository at this point in the history
Exclude MultiCheckbox and Radio because they can cause issues.
  • Loading branch information
Cruiser13 committed Nov 10, 2016
1 parent 40d27ea commit 4329ff2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion library/Twitter/Bootstrap3/Form.php
Original file line number Diff line number Diff line change
Expand Up @@ -449,7 +449,7 @@ public function addElement($element, $name = null, $options = null)
}

//Set HTML5 required attribute if this element is required and not excluded
$types_for_html5_excluded = array('note', 'html');
$types_for_html5_excluded = array('note', 'html', 'multiCheckbox', 'radio');
if(!in_array($type,$types_for_html5_excluded)){
if($element->isRequired()){
$element->setAttrib('required','required');
Expand Down

0 comments on commit 4329ff2

Please sign in to comment.