How to apply a function to a sequence of nodes in XSLT
问题 I need to write an XSLT function that transforms a sequence of nodes into a sequence of strings. What I need to do is to apply a function to all the nodes in the sequence and return a sequence as long as the original one. This is the input document <article id="4"> <author ref="#Guy1"/> <author ref="#Guy2"/> </article> This is how the calling site: <xsl:template match="article"> <xsl:text>Author for </xsl:text> <xsl:value-of select="@id"/> <xsl:variable name="names" select="func:author-names(