I suspect $_ is not what you think it is in the print. Try to get it to work using explicit variables first (one for the file content, one for the regex, and one for the match), then you can watch what happens as you remove them.
I don't mean to be cryptic, but I think you're on the right track here...
In reply to Re: Using a regex saved in an environment variable
by bobf
in thread Using a regex saved in an environment variable
by J0ax88
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |