xsl-list
[Top] [All Lists]

Re: format-number()-function question

2003-12-18 14:52:10
"format-number($number, 
you don't need a variable there, you can just do
"format-number(., 

Also, when yiu _do_ need a variable don't do

<xsl:variable name="number"><xsl:value-of select="."/></xsl:variable>

do

<xsl:variable name="number" select="."/>

not only is it a lot less typing it's usually a lot more efficient, the
former makes a result tree fragment with a root node and a child text
node with string value the string value of the current node, the latter
makes the variable bound to the current node.

David

-- 
http://www.dcarlisle.demon.co.uk/matthew

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



<Prev in Thread] Current Thread [Next in Thread>