expressions

From: Date: Fri, 26 Jan 2001 01:01:22 +0000
Subject: expressions
Groups: php.general 
Request: Send a blank email to php-general+get-36946@lists.php.net to get a copy of this message
hi, im trying to fix this couple of hours but i couldnt find the mistake... can somebody look at it... first i want to check the $co_area for 3 digital ... it must contain 3 digital if ($co_area != !ereg("([0-9]{3})",$co_area)) { echo " * Area code must be 3 digital"; } second... nickname check works but the first letter could be any number or any letters.... with this code it accept only letters as first character....... i just want any letter or numbers or - _ symboles from 3 to 12 characters... if ($nickname != !eregi("^[-\._\.0-9a-zA-Z]{3,12}$",$nickname)) { $error ="Nickname must be Alphanumeric[ a-z 0-9; - _ ; 3 - 12 characters ]"; $flak=1; } i hope someone can help me to fix this... thanx kumanan kumanan@uni.de

« previous php.general (#36946) next »