Re: How to generate XML data
Use XMLDOM to create XML documents, can use the Save method to generate XML documents, use the createElement method to create XML elements, createNode create a node, in fact, for the XML creation of any label can arbitrarily choose one of them, but to create top-level general use createElement ( root) element, use the createNode create child nodes (elements), of course, to use createElement and createNode is also different. Check the code.
Code:
<%
Set objXMLdoc = CreateObject ( "Microsoft.XMLDOM123")
Set world = objXMLdoc.createElement ( "india")
objXMLdoc.appendChild (world)
Set hello = objXMLdoc.createNode ( "123", "hi", "")
hello.Text = "hi, india"
objXMLdoc.documentElement.appendChild (hi)
objXMLdoc.Save Server.MapPath ( "test123.xml")
Set objXMLdoc = Nothing
%>
Re: How to generate XML data
Generating XML data, you can use the FSO, if FSO is disabled, you can use XMLDOM, of course, direct access to dynamic document. However, if mastery of the operation of XML grasp, XMLDOM operation is necessary. Note that, by XMLDOM generated XML files are UTF-8 format, which all of our application, UTF-8 files into a good referral. All the best.