Hello
Correct this code please
Here's the code ::
//----------------------------------------------------------
$temps = array('.com','.biz','.info','.net','.org','.us', '.name','.in','.co','.in','.tv','.cc','http');
$name = "site .com";
foreach ($temps as $index => $nilai){
if (ereg($nilai,$name,$regs)){
$err = "no url please in name";
}
}if ($err!=""){die("you can't insert url in name field");}
//----------------------------------------------------------
why when I change the value of $name into "site com", the result is same(.com is still find in variable name)? I want only the ".com" that should be forbidden and show that message. Please help me, I need it urgent.
Thanks a lot
-- This message may have been cut off and the rest will only be shown to members. To become a member, click here --