Skip to Main Content
Programming ColdFusion MX, 2nd Edition
book

Programming ColdFusion MX, 2nd Edition

by Rob Brooks-Bilson
August 2003
Intermediate to advanced content levelIntermediate to advanced
1140 pages
68h 45m
English
O'Reilly Media, Inc.
Content preview from Programming ColdFusion MX, 2nd Edition

Name

XmlParse

Synopsis

                  
                  
                  XmlParse(XML_string [, case_sensitive])

Converts an XML string to a ColdFusion XML document object. Setting the optional case_sensitive parameter to Yes causes ColdFusion to maintain the original case of the XML document elements and attributes. The default value for case_sensitive is No. The following example retrieves an XML file from the Macromedia web site and parses it into a ColdFusion XML document object:

<cfhttp URL="http://www.macromedia.com/devnet/resources/macromedia_resources.xml"
        method="Get">
   
<cfset DesDev = XmlParse(cfhttp.FileContent)>
   
<cfdump var="#devnet#">

Note that XML encoded in character sets other than ASCII or Latin-1 must have the character set explicitly defined to ColdFusion. If you are using the cffile tag to read an XML file, the character set can be defined using the charset parameter of the cffile tag. If the XML file is retrieved via another method, it may be necessary to first change the encoding.

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Programming ColdFusion

Programming ColdFusion

Rob Brooks-Bilson

Publisher Resources

ISBN: 0596003803Supplemental ContentErrata Page