[XSL-LIST Mailing List Archive Home]
[By Thread]
[By Date]
Re: xsl:import vs xsl:include
Subject: Re: xsl:import vs xsl:include From: Tony Graham <tgraham@xxxxxxxxxxxxxxxx> Date: Wed, 25 Aug 1999 06:19:20 -0400 (EST) |
At 25 Aug 1999 10:46 +0200, Sebastien Sahuc wrote: > As I'm trying to perform tests on several XSL processors, and I have > style sheets using xsl:import statement to import common named > template and variable decalration, I cannot use them with SAXON since > it does not implement it. > > So question : can I instead use iclude statement ? What the > differences as I don't sdee any from the WD of XSLT. There are differences. Stylesheets that you reference with xsl:import have a lower "import precedence" than the importing stylesheet, whereas stylesheets you reference with xsl:include are almost completely treated as if you'd copied the referenced file and pasted it into your stylesheet at that point. For example, if you had template in both the main and the referenced stylesheet with the same match pattern. With xsl:import, you wouldn't get a conflict because the main stylesheet has higher "import precedence" (plus there's rules about import precedence of multiple imported stylesheets). With xsl:include, you would get an error because the template in the referenced stylesheet is treated as if it were in the main stylesheet, and two templates matching the same pattern will cause an error. Regards, Tony Graham ====================================================================== Tony Graham mailto:tgraham@xxxxxxxxxxxxxxxx Mulberry Technologies, Inc. http://www.mulberrytech.com 17 West Jefferson Street Direct Phone: 301/315-9632 Suite 207 Phone: 301/315-9631 Rockville, MD 20850 Fax: 301/315-8285 ---------------------------------------------------------------------- Mulberry Technologies: A Consultancy Specializing in SGML and XML ====================================================================== XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
xsl:import vs xsl:include, Sebastien Sahuc | Thread | result indenting, Linda van den Brink |
RE: sort question, Kay Michael | Date | result indenting, Linda van den Brink |
Month |