[geeklog-users] fix in COM_isemail

Lucas Gonze lgonze at panix.com
Tue Dec 9 15:43:45 EST 2003


I added '+' character to the list of allowed chars in on the left side 
of an email address.  This permits email addresses like 
joe+geeklog at site.com, which some people use to flag the source of spam.

New code:
function COM_isemail( $email )
{
     if( eregi( 
"^([-_0-9a-z+])+([-._0-9a-z+])*@[0-9a-z+]([-.]?[0-9a-z])*.[a-z]{2,3}$", 
$email, $check ))
	  // was:
	  // if( eregi( 
"^([-_0-9a-z])+([-._0-9a-z])*@[0-9a-z]([-.]?[0-9a-z])*.[a-z]{2,3}$", 
$email, $check ))
     {
         return TRUE;
     }
     else
     {
         return FALSE;
     }
}




More information about the geeklog-users mailing list