xsl-list
[Top] [All Lists]

RE: xslt regex escaping

2004-08-17 05:02:07
 

    -----Original Message-----
    From: Ragulf Pickaxe 

    I don't know much about escaping regular expressions in 
    XSLT2, but depending on whether you have single or multiple 
    lines and how you manage them, you may have problems on 
    your evaluations perhaps being too greedy.
    
    But this is perhaps not your problem?
Hi.
  No, David C hit on it. I was looking for a regex escape,
and the problem is with using " instead of "
i.e. attribute escaping instead of regex escaping.

  Equally I should have used ' instead of ' .

I've hit and solved (for now) the 'too greedy' option!
search for Regex is: [^W.*([0-9][0-9])] 
at http://www.dpawson.co.uk/xsl/rev2/regextestbed.html

Apparently the regex engine has to back off the .* greediness
in order to satisfy the two digits.

Thanks David.

-- 
DISCLAIMER: 

NOTICE: The information contained in this email and any attachments is 
confidential and may be privileged. If you are not the intended 
recipient you should not use, disclose, distribute or copy any of the 
content of it or of any attachment; you are requested to notify the 
sender immediately of your receipt of the email and then to delete it 
and any attachments from your system. 

RNIB endeavours to ensure that emails and any attachments generated by 
its staff are free from viruses or other contaminants. However, it 
cannot accept any responsibility for any  such which are transmitted.
We therefore recommend you scan all attachments. 

Please note that the statements and views expressed in this email and 
any attachments are those of the author and do not necessarily represent 
those of RNIB. 

RNIB Registered Charity Number: 226227 

Website: http://www.rnib.org.uk 


<Prev in Thread] Current Thread [Next in Thread>