in reply to How to gracefully deal with a regex problem
with $var containing some strange characters, to produce the error message? If so, simply quote the string $var ala:$test=~/$var/;
The quote-escape (sorry, don't know their real name) operators are extremely useful for situations like this. Check out perlop for more information.$test=~/\Q$var\E/;
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: How to gracefully deal with a regex problem
by michellem (Friar) on Mar 07, 2001 at 02:14 UTC |