note 55119 deleted from function.ereg by nlopess

From: Date: Sun, 02 Oct 2005 18:06:04 +0000
Subject: note 55119 deleted from function.ereg by nlopess
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-96209@lists.php.net to get a copy of this message
Note Submitter: karl at xtronics dot com ---- // Valid postal zip code? $len = strlen($zip); switch ($len){ case 5: if (ereg ("[0-9][0-9][0-9][0-9][0-9]",$zip) !=1) $error_code = 1; break; case 10: if (ereg ("[0-9][0-9][0-9][0-9][0-9]-[0-9][0-9][0-9][0-9]",$zip) !=1) $error_code = 1; break; default: $error_code = 1; }

« previous php.notes (#96209) next »