Subject: Re: [xsl] Re: Capturing/testing results of a boolean expression. From: Mike Brown <mike@xxxxxxxx> Date: Fri, 2 Aug 2002 19:06:50 -0600 (MDT) |
Edward L. Knoll wrote: > I have a variable which will have a string value. I wish to compare > that string value to another string value (which happens to be a literal > value). I've done this directly in a xsl:if or xsl:when before, but now > I'm trying to capture the results of the expression in a variable. > > <xsl:variable name="X" ..../> > > <xsl:variable name="flag" select="$X = 'literal-string-value'" /> That does in fact do exactly what you want. Wherever that flag variable is in scope, it is a boolean object and you can use $flag in an XPath expression as such. You will need to post more details of how this is not doing what you expect. What type of object is $X, for example? - Mike ____________________________________________________________________________ mike j. brown | xml/xslt: http://skew.org/xml/ denver/boulder, colorado, usa | resume: http://skew.org/~mike/resume/ XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [xsl] Re: Capturing/testing res, Wendell Piez | Thread | [xsl] Any way to intergate for the , Edward L. Knoll |
Re: [xsl] Any way to intergate for , Mike Brown | Date | [xsl] Efficiency, use param in key?, Christopher_Dant |
Month |