note 5615 deleted from function.ereg by jimw

From: Date: Fri, 02 Nov 2001 01:20:41 +0000
Subject: note 5615 deleted from function.ereg by jimw
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-20114@lists.php.net to get a copy of this message
Here's the best email validation function (pulled from the best of all of the postings on the eregi() and mail() pages: <pre> function valid_email ($email) { if (eregi("^[0-9a-z]([-_.]?[0-9a-z])*@[0-9a-z]([-.]?[0-9a-z])*\\.[a-z]{2,3}$", $email, $check)) { if ( getmxrr(substr(strstr($check[0], '@'), 1), $validate_email_temp) ) { return TRUE; } } return FALSE; } </pre>

« previous php.notes (#20114) next »