Subject: Re: [xsl] case insensitive attributes From: David Carlisle <davidc@xxxxxxxxx> Date: Thu, 5 Apr 2001 18:09:12 +0100 |
> Actually, the all caps ADMIN was just for testing. but as Jeni (and I) pointed out the test always fails as you lowercase the attribute then test against something uppercase. > It could come in as Admin ADmin ADmiN or anything > like that. It comes from user input to a login form. exactly, that;s why you apply thetranslate function to lowercase everything so all of thos become admin. but thenyou need to test against admin not ADMIN. > ended up using this and it seems to be working, but > I am not sure how efficient it will be. > root/CamUsers[@UserId = translate(@UserId,'ABCDEFGHIJKLMNOPQRSTUVWXYZ', > 'abcdefghijklmnopqrstuvwxyz') = 'Admin'] efficiency isn't an issue, it never returns any nodes. No value of @UserId, after being lowercased will ever be equal to 'Admin' David _____________________________________________________________________ This message has been checked for all known viruses by Star Internet delivered through the MessageLabs Virus Control Centre. For further information visit http://www.star.net.uk/stats.asp XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [xsl] case insensitive attribut, Jeni Tennison | Thread | RE: [xsl] case insensitive attribut, James Eberhardt |
Re: [xsl] case insensitive attribut, Jeni Tennison | Date | Re: [xsl] Embedding HTML in JSP, Jeni Tennison |
Month |