Skip to content

Commit 9b3df90

Browse files
dpf-ddskerbis
authored andcommitted
Update mform_default.php
Fixed: Ignoring the value of call `$form->setLabelColClass('my_value')`
1 parent 8c2bdaa commit 9b3df90

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

fragments/mform/mform_default.php

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,9 @@
77
$this->setVar('labelColClass', 'col-sm-2 control-label');
88
$this->setVar('formItemColClass', 'col-sm-10');
99
break;
10+
case 'default_custom':
11+
/* $this->getVar('labelColClass') and $this->getVar('formItemColClass') already have the correct values from the call. */
12+
break;
1013
case 'default_full':
1114
case 'default_custom_full':
1215
$this->setVar('labelColClass', 'col-sm-12');
@@ -20,4 +23,4 @@
2023
$inputWrapperClose = ($this->getVar('notCloseInputWrapper')) ? '' : '</div>';
2124
$formGroupClose = ($this->getVar('notClosedFormGroup')) ? '' : '</div>';
2225

23-
echo '<div class="form-group ' . $this->getVar('class') . '">' . $labelWrapperOpen . $this->getVar('label') . $this->getVar('infoTooltip') . $this->getVar('infoCollapseButton') . $labelWrapperClose . $inputWrapperOpen . $this->getVar('element') . $inputWrapperClose . $formGroupClose . $this->getVar('infoCollapse');
26+
echo '<div class="form-group ' . $this->getVar('class') . '">' . $labelWrapperOpen . $this->getVar('label') . $this->getVar('infoTooltip') . $this->getVar('infoCollapseButton') . $labelWrapperClose . $inputWrapperOpen . $this->getVar('element') . $inputWrapperClose . $formGroupClose . $this->getVar('infoCollapse');

0 commit comments

Comments
 (0)