in reply to regex search fails
Change the line in the loop to
print if /\Q$pattern\E/;
This is equivalent to $pattern= quotemeata($pattern); before the loop. The '$' in your pattern is interpreted as special char in your regex, thats why it isn't working
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: regex search fails
by ikegami (Patriarch) on Mar 12, 2009 at 15:09 UTC |