xmlDocument
Create a new XML document
Syntax
xdoc = xmlDocument([uri, [, version]])
Arguments
- uri
a string giving document uri
- version
a string giving the XML version ofthe document
- xdoc
a mlist typed XMLDoc
Description
Create a new XML document.
Examples
xdoc = xmlDocument("TMPDIR/foo.xml"); root = xmlElement(xdoc, "root"); root.attributes.attr = "value"; root.children(1) = "<a>hello</a>"; root.children(2) = xmlElement(xdoc, "b"); root.children(2).attributes.id = "123"; root.children(2).content = " world"; xdoc.root = root; xmlDump(xdoc) xmlDelete(xdoc);
See also
- XML Objects — Describe the properties of the different XML objects
- xmlElement — Create a new XML element
History
| Version | Description |
| 5.4.0 | XML module introduced. |
| Report an issue | ||
| << xmlDelete | XML Management | xmlDump >> |