Hey Monica,
This is actually pretty easy. In the code, I'm converting an xml output to html. If you want the xml output directly, the soap response is an xml file.
Therefore below is the code to alert out the xml file. Just as a matter of curiosity, what specifically are you trying to do with the xml file?
-
// Execute the SOAP request
objXMLHTTP.setRequestHeader ("SOAPAction", action);
objXMLHTTP.setRequestHeader ("Content-Type", "text/xml");
objXMLHTTP.send(SOAPEnvelope);
if (objXMLHTTP.status != 200)
{
SOAPResponse.innerHTML = objXMLHTTP.responseText;
}
else
{
// Show SOAP Response
objXMLDOM.loadXML(objXMLHTTP.responseXML.xml);
// Translate SOAP Response to HTML and show HTML
//Comment out the following line:
//LoadXSL( xsl, HTMLResponse);
//alert out xml file...
alert(objXMLHTTP.responseXML.xml);
}
-