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

RE: import/include and apply-imports

Subject: RE: import/include and apply-imports
From: "Tim Watts" <timw@xxxxxxx>
Date: Thu, 10 May 2001 10:16:46 +1000
RE:  import/include and apply-imports
Janning

As I understand it, there can be only one <template match="book"> in an xsl.

If first.xsl has a <template match="book"> that will be used over the ones
from  the included xsl's, and otherwise if there are more than one then the
last one is used (in Saxon - depends on the XSL Parser I think)

As second.xsl is imported after third.xsl, only the template match in
second.xsl is used.

Otherwise, what would the processor do?  Which should it use? It wouldn't
make sense to have more than one template matching the same node.

I'm pretty sure I read about this in Michael Kays XSLT book, but he may
clarify your question.

Tim :)
-----Original Message-----
From: Janning Vygen
Sent: Thursday, 10 May 2001 3:19 AM
Subject:  import/include and apply-imports

first.xsl:
------
<xsl:import href="third.xsl">
<xsl:include href="second.xsl">

second.xsl
--------
<template match="book">
  <xsl:apply-imports/>
</template>

third.xsl
------
<template match="book">
  AM I EVER EVER MATCHED?
</template>


the template in the third.xsl is NEVER matched!!
Why? I thought, that include means, the stylesheet is included like it was
always in this file??

Janning


 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.