'defer' Example : defer « Object « HTML / CSS






'defer' Example


<html>
<head>
<SCRIPT LANGUAGE="Javascript" defer='false'>
function function1()
{
  var islandRoot = document.all["myXML"].XMLDocument;
  alert(islandRoot.nodeName);
}
</SCRIPT>

<SCRIPT LANGUAGE="XML" id="myXML">
<offerings>
 <class>
     <materials>This should render.</materials>
     <time>1.5hr</time>
     <professor>P</professor>
     <classRoomNumber>101</classRoomNumber>
 </class>
</offerings>
</SCRIPT>

</head>
<body>
<button onclick="function1()">Test the XML Data Island</button>
</body>
</html>

      
      








Related examples in the same category