|
[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Re: String length question
Marcio Ferreira wrote:
Hi Marcio,I want to now the sum of the lengths of attribute descriptions in the xml below I think "string-length(descendant::folder/@description)" will only test one description attribute (the first in document order). Possible solution: first collect all the descriptions inside a variable, then use string-length on that variable: <xsl:template match="folder" mode="left_menu"> <xsl:variable name="all-descriptions"> <xsl:copy-of select="descendant::folder/@description"/> </xsl:variable> <xsl:variable name="sizeTotal" select="string-length($all-descriptions)"/> ... </xsl:template> HTH, Anton
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|

Cart








