in reply to matching white spaces in perl

Of course given the sample data the inevitable followup remark should be, ". . . But you really don't want to use just regexen to parse (SG|X)ML; use a real parser if this is anything other than very simple and a static format."

The cake is a lie.
The cake is a lie.
The cake is a lie.

Replies are listed 'Best First'.
Re^2: matching white spaces in perl
by moritz (Cardinal) on Oct 06, 2008 at 15:09 UTC
    ... and even for simple XML you shouldn't use regexes, because it's not going to stay simple.