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

Re: finding position() of an element in a different co

Subject: Re: finding position() of an element in a different context
From: Jeni Tennison <mail@xxxxxxxxxxxxxxxx>
Date: Thu, 3 May 2001 12:52:41 +0100
finding position textnode page
Hi Kevin,

> This sounds promising, so I tried it. At first it again did not work.
> While testing I noticed that I was setting variables as follows:
>
>    <xsl:variable name="formtypeID"><xsl:value-of select="@id"/></xsl:variable>
>
> When I change this to:
>
>    <xsl:variable name="formtypeID" select="@id"/>
>
> Everything started working fine. Is the first returning the text
> value of @id, while the second is actually returning the attribute
> node itself or something??

Yes, that's basically right.  Actually the first returns a result tree
fragment, made up of a root node with a single child text node that
has a string value that is the value of id attribute.  If you're only
ever using the string value of $formtypeID then it shouldn't matter
which you use.

Cheers,

Jeni

---
Jeni Tennison
http://www.jenitennison.com/



 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.