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

Re: simple XSL

Subject: Re: simple XSL
From: David Carlisle <davidc@xxxxxxxxx>
Date: Tue, 18 Apr 2000 22:18:23 +0100 (BST)
simple xsl match
   >
   >> <xsl:template match="*/C">
   >
   >that is equivalent to 
   ><xsl:template match="C">
   >except it doesn't match the document element.


   really?

yes

   i thought 

   match="*/C" 

   would match all C grandchildren elements

   while

   match="C"

   would match all C children elements


   am i wrong?

no, you are right (and describing the same set of C nodes as me)

the set of C elements for which there exists a node such that the C
element is a grandchild is every C element in the document, except
the top level element (if that is a C). 

The definition of a match  in xsl is just exactly that, that
_some_ (any) node exists, such that taking that node as the current node
the node to be matched is selected by the expression.

so an element C matches match="C" because you can start at the parent
node then select="C" would select the element.

similarly every C element that has a grandparent matches match="*/C".

David



 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.