From: John E. Simpson [mailto:[log in to unmask]]
Sent: Friday, September 29, 2000 9:27 AM
To: [log in to unmask]
Subject: Re: <xsl:include>
At 08:58 AM 09/29/2000 -0400, Silvia, Michael wrote:
>Does any one has any good examples of include in use ?
Mike, are you having a problem with it? It's fairly simple to create a
1. Start with any working XSLT stylesheet.
2. Cut the entire contents of any top-level element (like a template rule,
or a global xsl:variable setting) and paste into a new stylesheet. Add the
xsl:stylesheet wrapper to the new stylesheet, and save the whole thing
under some convenient name.
3. In the original stylesheet, replace the cut portion with an xsl:include
element whose href attribute points to the stylesheet created in step 2.
4. Save the original stylesheet.
The main thing you've got to be careful about is not including the same
stylesheet too many times, especially indirectly (e.g. A includes B, which
includes C, which includes D, which includes B). The problem that can occur
is that you end up with possibly conflicting template rules.
John E. Simpson | "If you were going to
http://www.flixml.org | shoot a mime, would you use
XML Q&A: http://www.xml.com | a silencer?" (Steven Wright)