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

Re: testing relationships between nodes

Subject: Re: testing relationships between nodes
From: Wolfgang Jeltsch <wolfgang@xxxxxxxxxxx>
Date: Thu, 14 Sep 2006 18:25:54 +0200
Re:  testing relationships between nodes
Am Donnerstag, 14. September 2006 18:19 schrieb Houghton,Andrew:
> > From: Wolfgang Jeltsch [mailto:wolfgang@xxxxxxxxxxx]
> > Sent: 14 September, 2006 12:16
> > To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx
> > Subject:  testing relationships between nodes
> >
> > Hello,
> >
> > alas, I cannot see any way to check whether a given node is
> > an ancestor of a given other node in XPath.  How do I do this?
>
> <x>
>  <y>
>   <z/>
>  </y>
> </x>
>
> <xsl:if test="exists(/x/y/z/ancestor::x)"/>
>
>
> Andy,

I meant concrete nodes, not classes of nodes (like all nodes with a certain 
QName).  I have a template with a parameter representing a concrete node.  I 
want to check whether this node is a descendant of the current node.

Best wishes,
Wolfgang

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-2011 All Rights Reserved.