If $firstchar = '(' then I get an unmatched ( error at runtime.#!/usr/bin/perl use strict; use CGI; ## stuff snipped for brevity my($firstchar) = substr($name,0,1); if($vartocheck =~ /$firstchar/i) { ## do stuff; } ## stuff snipped for brevity exit;
Is there an option such that the $firstchar will be used in the compare without causing this error?
Thanks for any clues
Claude
In reply to Regex question by Xxaxx
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |