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] | · | [̀-ͯ] |
[‿-⁀]')"/>
<xsl:variable name='Name.re'
select='concat($NameStartChar.re,
"(", $NameChar.re,")*")'/>
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
--~------------------------------------------------------------------
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--