|
[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Re: How to substitute a string based on number
msxml:node-set is a extension function and not a standard function. It
converts a result tree fragment into a nodeset. Different XSLT-processors
have different extension for this function, (if they need it at all).
A standard solution would be: Create a file monthnames.xml: -------------------------------------------- <monthnames> <month>January</month> <month>February</month> <month>March</month> <month>April</month> <month>May</month> <month>June</month> <month>July</month> <month>August</month> <month>September</month> <month>October</month> <month>November</month> <month>December</month> </monthnames> -------------------------------------------- and then your stylesheet could look like: -------------------------------------------- <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" > <xsl:variable name="monthnames" select="document('monthnames.xml')/monthnames/month/text()"/> <xsl:param name="month" select="1"/> <xsl:template match="/"> <test> <xsl:value-of select="$monthnames[$month]"/> </test> </xsl:template> </xsl:stylesheet> --------------------------------------------
At 04:37 29.10.2001 -0800, you wrote: Hello All, XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
|
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








