This is the mail archive of the xsl-list@mulberrytech.com mailing list .


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Retrieving @Name attribute of following Item.


I would try it with <xsl:value-of
select="following-sibling::Item[1]/@Name"/>. This gives you the @Name of the next following Item. For the 2nd next
Item/@Name you only need to change the [1] to [2] and so on.

Joerg

> Hi all,
> 
> After I caused somewhat of a ruck mentioning flowers and chocolates, I 
> now offer a small invisible prize to the solver of my next question.
> 
> XML:
> 
> <some-other-node>
>   <Data>
>     <Item Name="bob">val1</Item>	
>     <Item Name="gary">val2</Item>
>   </Data>
> </some-other-node>
> 
> I simply want to get the @Name attribute from the following Item node, 
> in the current node.
> 
> I'm thinking I may need to use the position() XPATH function? 
> 
> e.g.
> 
> <xsl:value-of select="../Item[position()=position() + 2]"/>
> 
> Or am I barking up the wrong tree?
> 
> Arf,
> 
> -Buzz.
> 
> 
> 
>  XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
> 

-- 
GMX - Die Kommunikationsplattform im Internet.
http://www.gmx.net


 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]