OLD | NEW |
1 <script> | 1 <script> |
2 var createNewElement = function (tag, id, text) { | 2 var createNewElement = function (tag, id, text) { |
3 var result = document.createElement(tag); | 3 var result = document.createElement(tag); |
4 result.setAttribute('id',id); | 4 result.setAttribute('id',id); |
5 result.innerHTML = text; | 5 result.innerHTML = text; |
6 return result; | 6 return result; |
7 }; | 7 }; |
8 | 8 |
9 var runTests = function () { | 9 var runTests = function () { |
10 var toremove = document.getElementById("toremove"); | 10 var toremove = document.getElementById("toremove"); |
11 toremove.parentNode.removeChild(toremove); | 11 toremove.parentNode.removeChild(toremove); |
12 }; | 12 }; |
13 </script> | 13 </script> |
14 | 14 |
15 <body onload="runTests()"> | 15 <body onload="runTests()"> |
16 <details open> | 16 <details open> |
17 <summary>summary <b id="toremove">to be removed</b> shouldn't have only
bold text.</summary> | 17 <summary>summary <b id="toremove">to be removed</b> shouldn't have only
bold text.</summary> |
18 </details> | 18 </details> |
19 </body> | 19 </body> |
OLD | NEW |