On 2/12/06, Bowen, Bruce <[EMAIL PROTECTED]> 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!

--Tom Phoenix
Stonehenge Perl Training

--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>


Reply via email to