Commit 912472ac authored by Ryan Herbert's avatar Ryan Herbert

form_builder.js use jquery for setting node text

For compatibility with FF32, IE7 and 8
parent 4a6e6912
Pipeline #43570 passed with stages
in 4 minutes and 31 seconds
......@@ -43,7 +43,7 @@ FormBuilder.prototype.build_label = function(txt, object, field) {
var l = document.createElement('label');
l.htmlFor = field + "_" + this.index;
l.id = object + "_" + field + "__label_" + this.index;
l.innerText = txt + ":";
$(l).text(txt + ":"); // for compatibility with older browsers (FF32, IE7/8)
return l;
}
......@@ -96,14 +96,14 @@ FormBuilder.prototype.build_div = function(type) {
d.appendChild(c);
var s = document.createElement('span');
s.className = "left form_label"
s.innerText = capitalise(type == 'generic' ? 'set' : type) + " " + (this.index+1);
$(s).text(capitalise(type == 'generic' ? 'set' : type) + " " + (this.index+1)); // for compatibility with older browsers (FF32, IE7/8)
d.appendChild(s);
return d;
}
FormBuilder.prototype.build_legend = function(text) {
var l = document.createElement('legend');
l.innerText = text;
$(l).text(text); // for compatibility with older browsers (FF32, IE7/8)
return l;
}
......
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