On Tue, 7 Aug 2001, Ashutosh Salgarkar wrote:
We are trying to search japanese keyword using a search string(in perl using
We are facing problem while searching a particular keyword as given below,
$searchStr =~ m/$key1/i
when $key1 contains ã?·ã?ªã?¼ã?º
We get an error as follows
/ã?·ã?ªã?¼ã?º/: unmatched  in regexp
Please suggest the solution to overcome the problem.
my $safe_key = quotemeta($key1);
$searchStr =~ m/$safe_key/;
is probably what you want. I am presuming you are trying to use m// to
search for exact string matches rather than exploiting the full regex
Programs must be written for people to read, and only
incidentally for machines to execute.
---Abelson and Sussman