- From: tom@xxxxxxxxxxxxxx (Tom Phoenix)
- Date: Sun, 12 Feb 2006 13:41:15 -0800
On 2/12/06, Bowen, Bruce <Bowenb@xxxxxxxxxxx> wrote:
I have a text string = "^0176 ^0176"
I have set $a = "^0176 ^0176";
I have set $b = "^0176 ";
I'm using text =~ s/$a/$b/g;
And the text string doesn't change.
The caret is a metacharacter. You may want to use \Q or the
quotemeta() function to quote metacharacters in the interpolated $a.
Hope this helps!
Stonehenge Perl Training
- From: Bruce Bowen