Subject: Re: [xsl] storing the result of a transformation in a param and evaluating the content From: David Carlisle <davidc@xxxxxxxxx> Date: Tue, 23 Nov 2004 10:16:08 GMT |
String-length only works if $content is a text node, on a result tree fragment, it returns false every time. or more exactly if it has any text nodes anywhere in its descendants. (You needn't use string-length you ca just use test="string($foo)" which is the same thing. But if teh variable only consists of elements with no text content this will test empty. I found that I can use an extension function like so: <xsl:param name="nodeSet" select="exsl:node-set($content)"/> almost every processor has a node-set extension (mozilla's transformix being an exception unfortunately) although not always in the exsltnamespace. It's more or less considered standard, and in xslt2 variables will automatically produce node-sets and no function will be needed. David ________________________________________________________________________ This e-mail has been scanned for all viruses by Star. 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 ________________________________________________________________________
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
RE: [xsl] storing the result of a t, Michael Kay | Thread | [xsl] XML help, Tiffany Blake |
RE: [xsl] Grouping by key, Osman Çınar Eren | Date | [xsl] DOCTYPE Declaration, news |
Month |