- 1). Open your XML document in Notepad or a dedicated coding editor.
- 2). Insert the following code into the top of the XML object:
if (window.XMLHttpRequest)
{//
xmlhttp=new XMLHttpRequest();
}
else
{//
xmlhttp=new ActiveXObject("Microsoft.XMLHTTP");
}
xmlhttp.open("GET","books.xml",false);
xmlhttp.send();
xmlDoc=xmlhttp.responseXML; - 3). Replace "books.xml" with the XML file you want to parse to Firefox users. Non-Mozilla users won't access that data.