pc:copy-of |
Evaluates an XPath expression and (if the result is a node set) returns a deep copy of all the nodes in the resulting node set. The result can be serialised as output XML or passed to a different directive (Example 3). Syntax The required select attribute is the XPath expression to be evaluated. The intended use is that the result is a node set. A "deep copy" of this resulting node set is returned. Such a "deep copy" includes all the nodes in the node set and all of these nodes' descendent nodes, attribute nodes and namespace nodes. If xpath evaluates to a string then this string is returned. If it evaluates to a number or boolean, this value is converted to a string and then returned. In this respect, <pc:copy-of> behaves in the same way as pc:value‑of. If xpath evaluates to an XML document, then this entire document is copied to the result tree:
Example 1
Example 2
Example 3
|