Emails allow + per RFC. Hat tip: crw
git-svn-id: http://svn.automattic.com/wordpress/trunk@1269 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
e550bff7d5
commit
a2551a08ad
|
@ -305,7 +305,7 @@ function convert_smilies($text) {
|
|||
|
||||
|
||||
function is_email($user_email) {
|
||||
$chars = "/^([a-z0-9_]|\\-|\\.)+@(([a-z0-9_]|\\-)+\\.)+[a-z]{2,4}\$/i";
|
||||
$chars = "/^([a-z0-9+_]|\\-|\\.)+@(([a-z0-9_]|\\-)+\\.)+[a-z]{2,6}\$/i";
|
||||
if(strstr($user_email, '@') && strstr($user_email, '.')) {
|
||||
if (preg_match($chars, $user_email)) {
|
||||
return true;
|
||||
|
|
Loading…
Reference in New Issue