Subject: Re: [xsl] Problem with case-sensitivity From: "Werner, Wolfgang" <mail@xxxxxxxxxxxxxxxxxxx> Date: Fri, 01 Oct 2004 11:24:40 +0200 |
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1
you could translate both values to uppercase using the translate function before comparing them: <xsl:variable name='s1' select='translate(@name,"abcdefghiklmnopqrstuvwxyz","ABCDEFGHIKLMNOPQRSTUVWXYZ")'/> <xsl:variable name='s2' select='translate($name,"abcdefghiklmnopqrstuvwxyz","ABCDEFGHIKLMNOPQRSTUVWXYZ")'/>
<xsl:if test='contains($s1,$s2)'> ... </xsl:if>
hth, Wolfgang
Luke Ambrogio wrote: | Dear all, | | when i use the function: | | contains(@name,$name) | | it returns true only if even the case are the same, how do i go about making | it work even when the case is different i.e if @name = luke and $name = Luke | returns true? | | thanks in advance, regards | Luke Ambrogio | | | |
-----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.4 (Cygwin) Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org
iD8DBQFBXSJYqjaicDyx8o8RAhayAJ9zM6AgT29o7jaiS3gXFFGRCa2cHQCfeVBR 8a9Ocg7m8HF8fa2vptAUy1w= =rpl8 -----END PGP SIGNATURE-----
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
RE: [xsl] Problem with case-sensiti, Michael Kay | Thread | [xsl] xsl:apply-template and xsl:fo, Luke Ambrogio |
RE: [xsl] Problem with case-sensiti, Michael Kay | Date | Re: [xsl] XPatch: ancestor and coun, Anton Triest |
Month |