[XSL-LIST Mailing List Archive Home] [By Thread] [By Date]

Re: [xsl] Escaping Characters in replace()

Subject: Re: [xsl] Escaping Characters in replace()
From: David Carlisle <davidc@xxxxxxxxx>
Date: Tue, 15 Oct 2013 18:26:56 +0100

On 15/10/2013 17:44, Nathan Tallman wrote:
Thank you, David. Unfortunately, I still get ". after processing...

Presumably the template never matched.

(I'm transforming XML to HML, btw.)

Also, a question. Why didn't you need to escape the period in the
third argument of replace()?

You need \. to mean a literal . in a regular expression, not in the replacement text.

> (When I inert one, my processor throws an
error; so, I understand it's wrong, but not why. Also, I seem to be
able to delete the backslash in front of the period in the second
argument without causing problems... Why is that?)

". is a legal regex but matches a " followed by any character


would change "x to ."


google plus: https:/profiles.google.com/d.p.carlisle

Current Thread