form_element helper now supports empty labels
This commit is contained in:
parent
20d4b1b1c3
commit
b97154d19e
|
@ -232,7 +232,11 @@ function form_select($name, $label, $values, $selected) {
|
||||||
* Rendert ein Formular-Element
|
* Rendert ein Formular-Element
|
||||||
*/
|
*/
|
||||||
function form_element($label, $input, $for = "") {
|
function form_element($label, $input, $for = "") {
|
||||||
|
if ($label == '') {
|
||||||
|
return '<div class="form-group">' . $input . '</div>';
|
||||||
|
}else {
|
||||||
return '<div class="form-group">' . '<label for="' . $for . '">' . $label . '</label>' . $input . '</div>';
|
return '<div class="form-group">' . '<label for="' . $for . '">' . $label . '</label>' . $input . '</div>';
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
Loading…
Reference in New Issue