- <?php
- function checkEmail($email)
- {
- if(eregi("^[a-zA-Z0-9_]+@[a-zA-Z0-9\-]+\.[a-zA-Z0-9\-\.]+$]", $email))
- {
- return FALSE;
- }
-
- list($Username, $Domain) = split("@",$email);
-
- if(getmxrr($Domain, $MXHost))
- {
- return TRUE;
- }
- else
- {
- if(fsockopen($Domain, 25, $errno, $errstr, 30))
- {
- return TRUE;
- }
- else
- {
- return FALSE;
- }
- }
- }
- ?>
<?php
function checkEmail($email)
{
if(eregi("^[a-zA-Z0-9_]+@[a-zA-Z0-9\-]+\.[a-zA-Z0-9\-\.]+$]", $email))
{
return FALSE;
}
list($Username, $Domain) = split("@",$email);
if(getmxrr($Domain, $MXHost))
{
return TRUE;
}
else
{
if(fsockopen($Domain, 25, $errno, $errstr, 30))
{
return TRUE;
}
else
{
return FALSE;
}
}
}
?>