RE: [xsl] transforming a stylesheet that has imports and includes

Subject: RE: [xsl] transforming a stylesheet that has imports and includes
From: Américo Albuquerque <aalbuquerque@xxxxxxxxxxxxxxxx>
Date: Fri, 4 Apr 2003 18:23:12 +0100
Hi

> -----Original Message-----
> From: owner-xsl-list@xxxxxxxxxxxxxxxxxxxxxx 
> [mailto:owner-xsl-list@xxxxxxxxxxxxxxxxxxxxxx] On Behalf Of 
> Andrew Welch
> Sent: Friday, April 04, 2003 10:20 AM
> To: Xsl-List (E-mail)
> Subject: [xsl] transforming a stylesheet that has imports and includes
> 
> 
> 
> hi all,
> 
> I need to do an indentity transform on a stylesheet that has 
> imports and includes - but as the stylesheet is treated as 
> xml the imports/includes wont be performed.  How can I get 
> the full stylesheet and then transform that? (Im using trax)
> 

You only need to do something like:

<xsl:template match="xsl:import|xsl:include">
 <xsl:apply-templates select="document(@href)/xsl:stylesheet/node()"/>
</xsl:template>




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


Current Thread