GetXMLDump

CAS XML Script Library

The GetXMLDump function converts the XML contained within an XMLDOM object to formatted HTML.  The HTML, returned as a BSTR, can be displayed within an HTML element.  This function works with any XML format, not just CAS XML taglists.

BSTR GetXMLDump(
  Object xmlDoc // XMLDOM object to convert to HTML for display
)


Parameters:
xmlDoc XMLDOM object containing XML to convert to HTML.

Return Value:
A BSTR containing the formatted HTML representing the elements in the XML.

Example:
function ShowGetPortDbg()
  {
  var Tl = xmlTlNew();
  xmlTlAddTag(Tl,"GET_PORTS_INFO",null);
  xmlTlAddTag(Tl,"REGISTERED_NAME","User1");
  xmlTlAddTag(Tl,"REGISTERED_PASSWORD","");

  var responseXML = xmlTlSend(Tl,Domain,Server,Protocol,ProxyURL);

    // Open a new window and dump the XML

  var win = window.open("","dbg","resizable=yes,scrollbars=yes");
  win.document.write("<body>");
  win.document.write(GetXMLDump(responseXML));
  win.document.write("</body>");
  }
See Also:
xmlTlNew, xmlTlSend, xmlTlGetTag