- 01
- 02
- 03
- 04
- 05
- 06
- 07
- 08
- 09
- 10
function check_email($address)
{
$regex = '/^((\"[^\"\f\n\r\t\v\b]+\")|([\w\!\#\$\%\&\'\*\+\-\~\/\^\`\|\{\}]+(\.[\w\!\#\$\%\&\'\*\+\-\~\/\^\`\|\{\}]+)*))@((\[(((25[0-5])|(2[0-4][0-9])|([0-1]?[0-9]?[0-9]))\.((25[0-5])|(2[0-4][0-9])|([0-1]?[0-9]?[0-9]))\.((25[0-5])|(2[0-4][0-9])|([0-1]?[0-9]?[0-9]))\.((25[0-5])|(2[0-4][0-9])|([0-1]?[0-9]?[0-9])))\])|(((25[0-5])|(2[0-4][0-9])|([0-1]?[0-9]?[0-9]))\.((25[0-5])|(2[0-4][0-9])|([0-1]?[0-9]?[0-9]))\.((25[0-5])|(2[0-4][0-9])|([0-1]?[0-9]?[0-9]))\.((25[0-5])|(2[0-4][0-9])|([0-1]?[0-9]?[0-9])))|((([A-Za-z0-9\-])+\.)+[A-Za-z\-]+))$/';
if (preg_match($regex, $address)) {
return true;
}
else {
return false;
}
}
guest 12.01.2009 18:30 # 0
guest 13.01.2009 11:24 # 0
Гы, зачетно.
guest 18.04.2009 00:35 # 0
Uchkuma 14.07.2010 12:47 # 0
tranquillity 01.03.2011 14:57 # 0
proweber1 02.02.2014 19:55 # 0
filter_var($adress, FILTER_VALIDATE_EMAIL);