fixed closing div on empty select
This commit is contained in:
parent
8df75742d2
commit
1d994cc5b8
|
@ -1320,8 +1320,9 @@ class htmlSelect extends htmlElement {
|
||||||
}
|
}
|
||||||
echo "</select>\n";
|
echo "</select>\n";
|
||||||
// if select box has only one element then show it as text
|
// if select box has only one element then show it as text
|
||||||
if ((sizeof($this->elements) == 1) && !$this->multiSelect && $this->transformSingleSelect) {
|
if ((sizeof($this->elements) < 2) && !$this->multiSelect && $this->transformSingleSelect) {
|
||||||
echo '</div>';
|
echo '</div>';
|
||||||
|
if (sizeof($this->elements) == 1) {
|
||||||
echo ' ';
|
echo ' ';
|
||||||
if ($this->hasDescriptiveElements) {
|
if ($this->hasDescriptiveElements) {
|
||||||
$keys = array_keys($this->elements);
|
$keys = array_keys($this->elements);
|
||||||
|
@ -1331,8 +1332,6 @@ class htmlSelect extends htmlElement {
|
||||||
echo $this->elements[0];
|
echo $this->elements[0];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
elseif (sizeof($this->elements) == 0) {
|
|
||||||
echo '</div>';
|
|
||||||
}
|
}
|
||||||
if ($this->transient) {
|
if ($this->transient) {
|
||||||
return array();
|
return array();
|
||||||
|
|
Loading…
Reference in New Issue