xml editor

Supported platforms

Compatible with Windows7 & Mac OS X Snow Leopard

Ready for data server software
[XSL-LIST Mailing List Archive Home] [By Thread] [By Date]

Re: [xsl] stylesheet organisation


Subject: Re: [xsl] stylesheet organisation
From: Andrew Welch <andrew.j.welch@xxxxxxxxx>
Date: Sat, 3 Sep 2011 15:11:12 +0100

On 3 September 2011 14:31, Jesper Tverskov <jesper@xxxxxxxxxxx> wrote:
> I'm sorry that I dropped "as far as I know" from my posting right
> before I hit the Send button, but I some times take chances in order
> to stir up things that makes it possible for all of us to learn
> something.

:)  You soon learn (or at least commit it to memory) when you answer
someone, and then others point out that your answer was wrong... it
worked for me anyway.

> I still feel that the spec pretty much says what I'm saying,
> http://www.w3.org/TR/xslt20/#import, and that most of the differences
> are due to the simple fact the xsl.import must be the first child.

The main thing to remember with xsl:import is that the order of the
imports takes precedence over everything including the priority
attribute.

If you have:

<xsl:import href="foo.xslt">
<xsl:import href="bar.xslt"/>

and then someone comes along and changes it to:

<xsl:import href="bar.xslt"/>
<xsl:import href="foo.xslt">

...then it can change the output.  Changing the priorities of any of
the templates won't make any difference... those in foo.xslt will
always win - which goes against your idea that it was ultimately just
the ordering of the templates underneath.

xsl:include can be in any order, it doesn't matter, and priorities
still have an effect.


-- 
Andrew Welch
http://andrewjwelch.com


Current Thread
XML Editor | XML Author | WYSIWYG Editors | Schema Editor | XSD Documentation | XSL/XSLT Editor | XQuery | XML Databases | SVN Client
© 2002-2011 SyncRO Soft Ltd. All rights reserved. | Sitemap | Privacy Policy | This website was created & generated with <oXygen/>®XML Editor