Can anyone help me with this, I need it to check if email also has a mx record and if it doesnt then exit like the one there
function validateEmail($fEmail, $fBannedHosts)
{
if (!eregi('^([_a-z0-9-]+)(.[_a-z0-9-]+)*@([a-z0-9-]+)(.[a-z0-9-]+)*(.[a-z]{2,4})$', $fEmail)) {exit('<center>Error : Incorrect email <a href="../submit.php">Go Back</a></center>');}
if ($fBannedHosts == 'free') {$fBannedHosts = array('hotmail.com', 'yahoo.com');}
$explode = explode('@', $fEmail);
if (in_array($explode[1], $fBannedHosts)) {exit('<center>Error : Your email host ' . $explode[1] . ' is not allowed by this site <a href="../submit.php">Go Back</a></center>');}
}