hello again i need some more help
this is the list of things i need this form to do
1. allow lower and upper case
2. allow spaces between letters
3. restrict the number of . , _ - if possible used in each nick
4.wanted the script set for was alphanumeric with the added exception of - _ . and "[:space:]"
here is the code im using
function checkName($nickname,$title){
$blockWord=array("xxx","xxxx","xxxxx","xxxxx","xxxxxx","xxxx","xxxxx","xxxxx","xxxx","xxxx","xxxx","xxxx","xxxxxxx","xxxxx","xxxx","xxxxx","xxxx","xxxxx");
$result="";
if(strlen($nickname)<4){
$result="$title minimum 4 characters!";
}
else if(eregi("([^_a-z.0-9-])",$nickname)){
$result="Invalid $title !";
}else{
for($i=0;$i<count($blockWord);$i++){
if(strtolower($nickname)==$blockWord[$i]) $result="$title \"".$blockWord[$i]."\" is reserved word !";
No one has replied yet! Why not be the first?
Sign in or Join us (it's free).