Syntax
XMLTransform XSLFile=<xsl-file> InputFile=<in-file> OutputFile=<out-file> Result=<result-var>Description
Transform an input XML file using a specified XSL stylesheet.Parameters
<xsl-file>
- The file containing the XSL stylesheet to be applied to the InputFile.
<in-file>
- The XML file to be processed.
<out-file>
- Optional. The output file. If this parameter is not specified, the output is returned in the Result.
<result-var>
- Optional. The result variable. This parameter is ignored if OutputFile is specified.
Remarks
Note that if both OutputFile and Result are specified, Result is ignored and the output is written to the file.Using XMLTransform is likely to be much faster then scripted XMLMatch and XMLSelect statements when large amounts of XML data must be processed.
The PhantomScript XML-handling statements are XMLMatch, XMLSelect, XMLSelectText, and XMLTransform.
Example
XMLTransform
XSLFile="convert.xsl"
InputFile="corpdata.xml"
OutputFile="corpdata2.xml"
The above script fragment processes the file corpdata.xml into corpdata2.xml using the XSL stylesheet contained in convert.xsl.