xsl-list
[Top] [All Lists]

RE: Selecting the first item from a tokenized string

2006-01-13 08:55:45
Michael Kay wrote:

You can't do 

<xsl:for-each select="/e/itemref">
  <xsl:value-of select="/f/item[(_at_)nr]"/>

because the context inside the predicate is wrong.

But you can do

<xsl:for-each select="/e/itemref">
  <xsl:value-of select="subsequence(/f/item, @nr, 1)"/> 

  Yes.  The current XPath node, part of the static context, is
obviously not the same for the two "@nr" expressions.  Actually, I
misunderstood your initial sentence.

  Sorry for the noise, amd thanks for the response,

--drkm



















        

        
                
___________________________________________________________________________ 
Nouveau : téléphonez moins cher avec Yahoo! Messenger ! Découvez les tarifs 
exceptionnels pour appeler la France et l'international.
Téléchargez sur http://fr.messenger.yahoo.com

--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--