in reply to How do I escape special characters like . / or | in a regular expression?

Precede the special characters with \ ie:
$filename=~/.*\.txt$/ # matches anything ending with .txt;
  • Comment on Re: How do I escape special characters like . / or in a regular expression?
  • Download Code