Manish -
Here's how I have transformed multiple input files of differing document
types into one output:
<xsl:template match="/">
<xsl:apply-templates select="document('input2.xml')" mode="type2"/>
<xsl:apply-templates select="document('input3.xml')" mode="type3"/>
</xsl:template>
<xsl:template match="/" mode="type2"/>
<!-- template for second input file -->
</xsl:template>
The first input file is the handled by templates with no mode attribute. The
other files are transformed by a set of templates with mode="type2", etc.
These templates, in turn, could also invoke other templates by
<xsl:call-template name="templatename">.
The additional file names can also be provided to the stylesheet using -PARAM
values on the command line and <xsl:param ...> elements..
- Gene Roske
[EMAIL PROTECTED]
-----------------------
Manish Balsara wrote:
>
> Hi
>
> We need to process three different input sources and apply an XSLT
> (different rules for each input source) to generate one single
> output. Does anyone know if this is possible with Xalan? If not are there
> any other alternatives besides writing XPath to extract the data and
> custom code to build the output XML?
>
> thanks
> manish