Figure 2   Modifying Tags on an onclick


<HTML>
<HEAD><TITLE>MIND SAMPLE</TITLE>
<SCRIPT LANGUAGE="JScript">
function changeTags() {
    document.all.HeadingTag.outerHTML = "<H1 ID=HeadingTag>The DHTML object 
        model!</H1>";
    document.all.HeadingTag.style.color = "red";
    document.all.TextTag.innerText = "It's Magic!";
    document.all.TextTag.align = "center";
    document.body.insertAdjacentHTML("BeforeEnd", "<P ALIGN=\"center\">It's
        Magic!</P>");
}
</SCRIPT>
<BODY onclick="changeTags()">
<H5 ID=HeadingTag>The DHTML object model!</H5>
<P ID=TextTag>Click anywhere</P>
</BODY>
</HTML>