xmlNew

Creates an XML document object.

xmlNew([casesensitive]) → returns xml

xmlNew Argument Reference

casesensitive boolean
Default: false

Maintains the case of document elements and attributes.
Default: false
Values:
  • true
  • false

Examples
Sample code invoking the xmlNew function

Here, We created myXml by using xmlNew function. Then created root node(sampleXml) for myXml and set the rootnode text

<cfset myXml = xmlNew()>
<cfset myXml.XmlRoot = xmlelemnew(myXml,"sampleXml")>
<cfset myXml.sampleXml.XmlText ="This is root node text">
<cfdump var="#myXml#">

Fork me on GitHub