[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

RE: <xsl:include> / <xsl:import>

Subject: RE: <xsl:include> / <xsl:import>
From: Heather Lindsay <heather.lindsay@xxxxxxxxxxxxx>
Date: Fri, 22 Dec 2000 13:19:59 -0500
include xsl stylesheet
Crude Example:

Including this stylesheet(myGlobals.xsl):

<xsl:stylesheet ....>
	<xsl:variable name="myVariable1" select="whatever"/>
	<xsl:variable name="myVar2" select="whateverElse"/>
	
	<xsl:template name="myNamedTemplate">
		your processing here
	</xsl:template>
</xsl:stylesheet>


My main stylesheet (which is in the same directory as myGlobals.xsl):

<xsl:stylesheet ......>
	<xsl:include href="myGlobals.xsl"/>
	<xsl:template match="/">
		<xsl:call-template name="myNamedTemplate"/>
	</xsl:template>
</xsl:stylesheet>

This is a crude example but gives the basic structure.  I hope this helps.
I could probably give you more specific help if you need it and if you let
me know what exactly you want to do. 

Good luck,
Heather


-----Original Message-----

Hi,
I have several global variables and named templates in my stylesheet. As I
am going to be having several of these stylesheets that repeatedly use these
variables and call these templates, I would like to have them outside of the
stylesheet and in some common stylesheet (like a library) so that my other
stylesheets could access them.
Is this possible using <xsl:include> or <xsl:import>? If yes, could someone
please give me a simple example.
Thanks,
Krish

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

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


Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.