[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] xslt 2.0 regex
I believe variable names follow the name construct http://www.w3.org/TR/REC-xml/#NT-Name [5] less the : Trying to interpret this in xslt <xsl:variable name="NameStartChar.re" as="xs:string"> $[A-Z]|_|[a-z] | [À-Ö] | [Ø-ö] | [ø-˿] | [Ͱ-ͽ] | [Ϳ-῿] | [‌-‍] | [⁰-↏] | [Ⰰ-⿯] | [、-퟿] | [豈-﷏] | [ﷰ-�] | [𐀀-] </xsl:variable> <xsl:variable name="NameChar.re" as="xs:string" select="concat($NameStartChar.re,' | - | . | [0-9] | · | [̀-ͯ] | [‿-⁀]')"/>
then in use <xsl:template match="*"> <xsl:if test="matches(@select, $Name.re,'x') "> <xsl:message> <xsl:value-of select="name()"/><xsl:text> </xsl:text> <xsl:value-of select="@select"/> <xsl:text> </xsl:text> </xsl:message> </xsl:if> ... For some reason the regex is matching on other than $.... and I can't see why? Any suggestions please. regards -- Dave Pawson XSLT XSL-FO FAQ. http://www.dpawson.co.uk
|
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
|