http://qs321.pair.com?node_id=557292


in reply to Re^3: Regex to replace a particular part of content
in thread Regex to replace a particular part of content

If it was a real world problem with real HTML/XML/whatever you would recommend some sort of parser rather than regular expressions. However, the OP asked for a regular expression (misguidedly) to modify a piece of unrealistic text (I can read between the lines as well as the next man, who's ever seen real world mark-up like that?:-). I've had some fun and learnt a few things trying to see if it could be done that way so I'm happy.

Cheers,

JohnGG

  • Comment on Re^4: Regex to replace a particular part of content