Commit 77096ca7 authored by Elias Villiger's avatar Elias Villiger
Browse files

B3613 - Only render label/input/note open/close tag when corresponding...

B3613 - Only render label/input/note open/close tag when corresponding checkbox in FE configuration is ticked. - refs #3613, closes #3613
parent 0bb99fd1
Pipeline #994 passed with stage
in 1 minute and 46 seconds
......@@ -767,14 +767,18 @@ EOF;
switch ($wrapType) {
case WRAP_SETUP_ELEMENT;
$openTag = $formElement[FE_FLAG_ROW_OPEN_TAG] ? $this->getRowOpenTag($class) : '';
$closeTag = $formElement[FE_FLAG_ROW_CLOSE_TAG] ? $this->wrap[WRAP_SETUP_ELEMENT][WRAP_SETUP_END] : '';
$closeTag = $formElement[FE_FLAG_ROW_CLOSE_TAG] ? $this->wrap[$wrapType][WRAP_SETUP_END] : '';
break;
case WRAP_SETUP_LABEL:
case WRAP_SETUP_INPUT:
case WRAP_SETUP_NOTE:
$openTag = $this->wrap[$wrapType][WRAP_SETUP_START];
$closeTag = $this->wrap[$wrapType][WRAP_SETUP_END];
$hasOpen = Support::findInSet($wrapType, $formElement[FE_WRAP_ROW_LABEL_INPUT_NOTE]);
$hasClose = Support::findInSet("/$wrapType", $formElement[FE_WRAP_ROW_LABEL_INPUT_NOTE]);
$openTag = $hasOpen ? $this->wrap[$wrapType][WRAP_SETUP_START] : '';
$closeTag = $hasClose ? $this->wrap[$wrapType][WRAP_SETUP_END] : '';
break;
default:
throw new UserFormException("Unknown wrap for FormElement.parameter '$wrapType'.", ERROR_MISSING_VALUE);
break;
......
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