Commit 8c453e41 authored by skodak's avatar skodak
Browse files

MDL-19030 fixed xhtml strictness when label attached to frozen element; merged...

MDL-19030 fixed xhtml strictness when label attached to frozen element; merged from MOODLE_19_STABLE
parent fc3ec2ca
......@@ -186,7 +186,7 @@ class HTML_QuickForm_Renderer_Tableless extends HTML_QuickForm_Renderer_Default
} else {
$id = $element->getName();
}
if (!empty($id)) {
if (!empty($id) and !$element->isFrozen()) { // moodle hack
$html = str_replace('<label', '<label for="' . $id . '"', $html);
$element_html = preg_replace('#name="' . $id . '#',
'id="' . $id . '" name="' . $id . '',
......
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