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

template mode - inheritable? - help

Subject: template mode - inheritable? - help
From: "Jiang, Peiyun" <Peiyun.Jiang@xxxxxxxxxxxxxx>
Date: Tue, 13 Jan 2004 11:53:07 -0400
xsl template mode
XML:
<doc>
   <a>texta<b>textb<c>textc</c></b></a>
</doc>

XSLT:
  <template match="doc" mode="m1">
     <xsl:apply-templates />
  </xsl:template>
  <template match="doc" mode="m2">
     <xsl:apply-templates />
  </xsl:template>

  <template match="a" mode="m1">
     <xsl:apply-templates />
  </xsl:template>
  <template match="a" mode="m2">
     <xsl:apply-templates />
  </xsl:template>

  <template match="b">
     <xsl:apply-templates />
  </xsl:template>

  <template match="c" mode="m1">
     <xsl:apply-templates />
  </xsl:template>
  <template match="c" mode="m2">
     <xsl:apply-templates />
  </xsl:template>

PROCESSING and QUESTION:
(1) When mode m1 for doc is matched and applied, will it apply mode m1 for
element c? Notice that the parent of c is b and does not have a mode
template. 

(2) If you have m1 and m2 for b, will m1 for doc select all m1 for its
descedants?

REAL Problem:
I want situation (1): doc m1 process c m1 and doc m2 process c m2 when
applied. Possible? 


Thanks.

Peiyun


 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.