in reply to Check on if statement
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.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: Check on if statement
by Anonymous Monk on Aug 17, 2002 at 19:51 UTC | |
by tommyw (Hermit) on Aug 17, 2002 at 21:47 UTC | |
by blaze (Friar) on Aug 17, 2002 at 20:08 UTC | |
by CukiMnstr (Deacon) on Aug 17, 2002 at 23:09 UTC |