This is the mail archive of the xsl-list@mulberrytech.com mailing list .


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: which file to include or copy or copy-of


> //// <xsl:include href="THE ACTIVE FILE=1"/> or
> //// <xsl:copy select="THE ACTIVE FILE=1"/> or
> //// <xsl:copy-of select="THE ACTIVE FILE=1"/>

<xsl:include> is for including other stylesheets and so the templates in the
current one. If you really only want to copy the content of the other
xml-files to the output-tree, try <xsl:copy-of
select="document('filename')"/>. A way with more influence is to store the
document in a variable and use it as normal node-sets:

<xsl:template match="/">
    <xsl:variable name="file" select="document('filename')"/>
    <xsl:for-each select="$file/rootelement/element">
        <!-- and so on -->
    </xsl:for-each>
</xsl:template>

Hope this helps,

Joerg


 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]