RE: [xsl] Outer Loop and Inner Loop

Subject: RE: [xsl] Outer Loop and Inner Loop
From: "Michael Kay" <mhk@xxxxxxxxx>
Date: Fri, 2 May 2003 22:38:43 +0100
> > <xsl:value-of select="[@ = '$some_variable']"/>
> > 
> > Does that work?
> > 
> 
> It would be faster to try it than to ask. In this case, what 
> you want is
> 
> <xsl:value-of select="[@ = $some_variable]"/>
> 
> (assuming, of course, that the variable really evaluates to 
> the string that you want).
> 
> Cheers,
> 
> Tom P
> 

You're having an off day, Tom. You've only corrected one of his four
errors. 

The other three are:

* You can't use a predicate (an expression in square brackets) on its
own
* @ needs to be followed by a NodeTest
* "=" always does a comparison of the value of a node, not its name or
its identity.

Michael Kay 


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


Current Thread