Commit f82aab2f authored by Marc Egger's avatar Marc Egger
Browse files

AbstractBuildForm.php: Render datalist if Parameter is set

parent 6f4e9df4
Pipeline #1487 passed with stage
in 2 minutes and 22 seconds
......@@ -2445,7 +2445,13 @@ abstract class AbstractBuildForm {
$formElement = HelperFormElement::prepareExtraButton($formElement, false);
$attribute .= $this->getAttributeFeMode($formElement[FE_MODE]);
$html = '<select ' . $attribute . '>' . $option . '</select>';
if (isset($formElement["datalist"])) {
$datalistId = $formElement[FE_HTML_ID] . '-datalist';
$html = '<input ' . Support::doAttribute('list', $datalistId) . $attribute . '><datalist '
. Support::doAttribute('id', $datalistId) . '>' . $option . '</datalist>';
} else {
$html = '<select ' . $attribute . '>' . $option . '</select>';
}
$html = $html . $this->getHelpBlock() . $formElement[FE_TMP_EXTRA_BUTTON_HTML];
return $html . $formElement[FE_INPUT_EXTRA_BUTTON_INFO];
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment