• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1<!doctype html>
2<html class="a">
3 <head>
4  <title>element.getElementsByClassName(): adding an element</title>
5  <script src="resources/common.js"></script>
6 </head>
7 <body class="a">
8  <p id="r">FAIL (script did not run)</p>
9  <script>
10   var collection = document.body.getElementsByClassName("a"),
11       ele = document.createElement("x-y-z")
12   ele.className = "a"
13   document.body.appendChild(ele)
14   t(collection, [ele])
15  </script>
16 </body>
17</html>
18