Commit 62bd919d authored by Stefano Crocco's avatar Stefano Crocco

Use textContent rather than innerHTML to obtain the label

If the <label> element has children, innerHTML includes the
corresponding tags, which shouldn't be displayed to the user.
textContent doesn't have this issue (it has other problems, but they
shouldn't matter in this situation).
parent 53158738
...@@ -6,7 +6,7 @@ function labelsForIdsInFrame(frm) { ...@@ -6,7 +6,7 @@ function labelsForIdsInFrame(frm) {
if (l.htmlFor != '') { if (l.htmlFor != '') {
var obj = frm.document.getElementById(l.htmlFor); var obj = frm.document.getElementById(l.htmlFor);
if (obj) { if (obj) {
res[obj.id] = l.innerHTML; res[obj.id] = l.textContent;
} }
} }
} }
......
Markdown is supported
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