W3C home > Mailing lists > Public > www-xsl-fo@w3.org > January 2003

Re: problems with <xsl:variable>

From: David Carlisle <davidc@nag.co.uk>
Date: Tue, 28 Jan 2003 09:48:13 GMT
Message-Id: <200301280948.JAA19746@penguin.nag.co.uk>
To: DonovanT@astrolabegroup.com
CC: www-xsl-fo@w3.org



This is not an FO question so this is the wrong list, you should be on
xsl-list@lists.mulberrytech.com
but anyway:

<xsl:when test="(string-length(origID) = 0) a
                               ^^^^^^

that is looking for an element called origID not a variable you want
 $origID
 ^
 ^

incidentally don't do

<xsl:variable name="origID">
              <xsl:value-of
Select="Statements/ClientStatements/StmtsClient/Client/original/ID"/>a
</xsl:variable>

which makes a result tree fragment containing a root node and a text
node,
do
<xsl:variable name="origID"
select="Statements/ClientStatements/StmtsClient/Client/original/ID"/>

(Ignoring the "a" that I'm assuming was a typo, ortherwise string-length
of $origID will never be 0 as it's always at least 2 with "a" and a
newline character at the end. and the fact that you had Select with a
capital S which is a syntax error)

David

________________________________________________________________________
This e-mail has been scanned for all viruses by Star Internet. The
service is powered by MessageLabs. For more information on a proactive
anti-virus service working around the clock, around the globe, visit:
http://www.star.net.uk
________________________________________________________________________
Received on Tuesday, 28 January 2003 04:49:18 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Wednesday, 3 October 2007 16:06:10 GMT