* Thus wrote [EMAIL PROTECTED] ([EMAIL PROTECTED]):
> 
> I believe I spoke too soon.  If I use isset() then even if I leave the
> field empty it still returns true.  I am trying to view the documentation for
> this function but php.net seems to be timing out now.

> > if (isset($_POST[MI]) && (preg_match('/^[[:alpha:]]{1,1}$/', $_POST[MI]) == 0))


That is because the browser is sending in the POST data:
MI=

Thus, php does set it to ''.

Use something like this instead:

  if (strlen($_POST['MI'])) ...


btw, you should really quote your array keys.

HTH,


Curt
-- 
"I used to think I was indecisive, but now I'm not so sure."

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to