in reply to Re: Re: regex problem with metachars
in thread regex problem with metachars
That's because \t is a regex metacharacter. If you only want to escape some metacharacters, you'll need to figure out which ones.
If you want to escape all metacharacters beside backslash, something like:
should do it.s/([^A-Za-z_0-9\\])/\\$1/g;
|
|---|