Perl Search and Replace Avoid Variable Interpolation
Posted
by Justin
on Stack Overflow
See other posts from Stack Overflow
or by Justin
Published on 2010-03-18T05:11:20Z
Indexed on
2010/03/18
5:21 UTC
Read the original article
Hit count: 756
I'm really getting my butt kicked here. I can not figure out how to write a search and replace that will properly find this string.
String:
$QData{"OrigFrom"} $Text{"wrote"}:
Note: That is the actual STRING. Those are NOT variables. I didn't write it.
I need to replace that string with nothing. I've tried escaping the $, {, and }. I've tried all kinds of combinations but it just can't get it right.
Someone out there feel like taking a stab at it?
Thanks!
© Stack Overflow or respective owner