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

RE: excluding descendants (and all of their descendant

Subject: RE: excluding descendants (and all of their descendants as well)
From: "Woods, Christopher" <cwoods@xxxxxxxxxxxxxxxxx>
Date: Thu, 1 Sep 2005 11:21:33 -0400
xsl excluding a descendant
Thanks to Antonio Mota, Michael Kay, Evan Lenz, and David Carlisle for
responding to my question.  The solution ultimately employed looked like
this:

<xsl:for-each select="descendant::text[@id and count(ancestor::system) =
$sysCo]">

where $sysCo is set equal to: count(ancestor::system)

-----Original Message-----
From: Woods, Christopher
Sent: Wednesday, August 31, 2005 1:36 PM
To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx
Subject:  excluding descendants (and all of their descendants as
well)


How does one find all text elements that are descendants of the first para
element but exclude any text element that is a descendant of the second system
element?

<techinfo>
  <system>
    <descinfo>
      <para-seq>
        <para>
          <text>The quick brown fox jumped over the lazy systems
engineer.</text>
          <text>Hello world.</text>
          <style>
            <text>In the matter of Jardyce v. Jardyce:</text>
          </style>
          <system>
             <descinfo>
                 <para-seq>
                     <para>
                          <text>Blah, blah, blah...</text>
                           <text>more gibberish.</text>
                           <style>
                               <text>Nasty, Brutish, and Short Attorneys at
Law</text>
                           </style>
                        </para>
                      </para-seq>
                  </descinfo>
               </system>
            </para>
         </para-seq>
      </descinfo>
   </system>
</techinfo>

Thanks very much.

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.