Greetings...

I am trying to determine a way in which to create a hyperlink from a text node, and I need to do so dynamically. As you can see from the code example below, the idea is to create a text node from an array element. However, I am stuck on how to create the hyperlink without using "document.write()".

Your assistance is greatly appreciated.

========================================
<body id="linkBody">
<script type="text/javascript">
var linkArray = new Array();
linkArray.push("Hyperlink");

divBody = document.getElementById("linkBody");
divLink = document.createElement("div");
divLink.setAttribute("id", "myLink");
divLinkText = document.createTextNode(linkArray[0]);
divLink.appendChild(divLinkText);
divBody.appendChild(divLink);
</script>
</body>
========================================

Respectfully,

ASP