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

Re: How to select a node with parents?

Subject: Re: How to select a node with parents?
From: chris <oneskiingfool@xxxxxxxxx>
Date: Thu, 12 May 2005 20:07:23 -0600
Re:  How to select a node with parents?
You are right, my terminology didn't make much sense.  I wanted to
copy, not select.  Essentially wanted to do something like a
<xsl:copy-of select="xxx"/> and have it bring over its ancestor nodes
rather than descendant nodes.  Sounds like templates is the only way
to go.  Thanks for your response.

On 5/12/05, Michael Kay <mike@xxxxxxxxxxxx> wrote:
> If you select a node, then it keeps its original parents, siblings,
cousins,
> and aunts. In your example, the output node has the same parent and
> grandparent but different siblings from the original. That means it isn't
> the same node as the original - it must be a copy.
>
> So you're not in the business of selecting nodes here, you are doing a copy
> with modifications; which means using the identity template overridden with
> templates for the nodes you want to modify, in the usual way.
>
> Michael Kay
> http://www.saxonica.com/

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.