3 var createNewElement = function (tag
, id
, text
) {
4 var result
= document
.createElement(tag
);
5 result
.setAttribute('id',id
);
6 result
.innerHTML
= text
;
10 var runTests = function () {
11 document
.getElementById("dt1").insertBefore(createNewElement("summary", "new1", "new 1"), document
.getElementById("summary1"));
16 <body onload=
"runTests()">
18 <summary id=
"summary1">summary
</summary>