xsl-list
[Top] [All Lists]

Re: [xsl] Finding first difference between 2 text strings

2009-09-14 15:11:12


I suppose the use of the ')' in the function could be replaced by a
character not occurring in the text data.

no that is inserting regexp grouping syntax, not just a placeholder character.


Since we're also processing just ASCII text, and not Unicode, I replaced
the hex codes in the translation with just a space for each special
character.

That won't work you need to use a different character for each
regexp-special character (any characters not in the data would do, but
they need to be distinct, otherwise you will find that a string of
"++++" is considered equal to a string "[[[[" as you have made them both
a string of spaces before starting the comparison.

David

________________________________________________________________________
The Numerical Algorithms Group Ltd is a company registered in England
and Wales with company number 1249803. The registered office is:
Wilkinson House, Jordan Hill Road, Oxford OX2 8DR, United Kingdom.

This e-mail has been scanned for all viruses by Star. The service is
powered by MessageLabs. 
________________________________________________________________________

--~------------------------------------------------------------------
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>
--~--