Even without the problem of recognising an empty string, since you're using a regular expression, it will recognise any string which contains a question mark (even if it's got other characters in the string).
what's wrong with brute force?
if ($foo eq '' || $foo eq '?') { do something; }
--
Tommy
Too stupid to live.
Too stubborn to die.
In reply to Re: Check on if statement
by tommyw
in thread Check on if statement
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |