View comments | RSS feed
Contents > Developing ColdFusion MX Applications > Using XML and WDDX > The XML document object PreviousNext

The XML document object

ColdFusion represents an XML document as an object, called an XML document object, that is much like a standard ColdFusion structure. In fact, most ColdFusion structure functions, such as StructInsert, work with XML document objects. For a full list of ColdFusion functions that work on XML document objects, see Functions for XML object management.

You can look at the overall structure of an XML document in two ways: a basic view and a DOM (Document Object Model)-based node view. The basic view presents all the information in the document, but does not separate the data into as fine-grained units as the node view. ColdFusion can access XML document contents using either view.


Contents > Developing ColdFusion MX Applications > Using XML and WDDX > The XML document object PreviousNext

ColdFusion 9 | ColdFusion 8 | ColdFusion MX 7 | ColdFusion MX 6.1 | ColdFusion MX | Forums | Developer Center | Bug Reporting

Version 6.1

Comments are no longer accepted for ColdFusion MX 6.1. ColdFusion 8 is the current version.

Comments


twillerror said on Dec 3, 2003 at 12:42 PM :
Is Macromedia ever going to add functionality to copy one element from one document to another. There are lots of cases where I need to take two XML feeds and combine the two. In a lot of a cases simplying adding onto the first feed would work great. Howerver, assigning a node from one document to another give the error message, wrong document. I understand that a node must belong to one and only one document, but some convience functions to move trees around would be nice.
jrunrandy said on Dec 4, 2003 at 12:04 PM :
This has been entered as enhancement request 53831.
isaac dealey said on Jul 15, 2004 at 7:13 PM :
probably the easiest way to do this currently would be to write the content out in another cfxml tag and remove the xml declaration at the top of the document, i.e.
<cfxml>
<parentnode>
#rereplacenocase(toString(doc1),"<\?.+\?>","")#
#rereplacenocase(toString(doc2),"<\?.+\?>","")#
</parentnode>
</cfxml>

obviously this won't work for all situations, but it should help with some.

 

RSS feed | Send me an e-mail when comments are added to this page | Comment Report

Current page: http://livedocs.adobe.com/coldfusion/6.1/htmldocs/xml3.htm