Hi there,

I want to display some data in HTML using XSL. I can use xml file to display in the HTML page. But, I want to do the same thing using XML Island embedded in to HTML (below "XMLID" xml portion)

I want to use loadXML() as in the below ProcessXML1(), how ca I convert this "XMLID" xml island to a string?

function ProcessXML1() {

var xmlDoc = new ActiveXObject("Msxml2.DOMDocument.4.0");
xmlDoc.async = false;
xmlDoc.resolveExternals = false;
if (xmlDoc.parseError.errorCode <> 0) {
var myErr = xmlDoc.parseError
alert("You have error " + myErr.reason);

Thanks in advance,

We're using ASP.NET with C#, the XML island comes from the database.


<xml id="XMLID">
<?xml version="1.0" ?>
<name> ABC
<cell>99999999 </cell>

<script language="JavaScript">
function ProcessXML() {
// Load XML
var xml = new ActiveXObject("Microsoft.XMLDOM")
xml.async = false
//xml.load("addresses.xml") -- This works fine, but I want to use above XML Island instead of this addresses.xml file

// Load XSL
var xsl = new ActiveXObject("Microsoft.XMLDOM")
xsl.async = false

// Transform

<input type="button" onClick=ProcessXML()>