I have tried different examples that I get through google.com and the
PHP manual, but no-one of them work.
Here is one of them I have tried:
(Well, I have put some echo sentence i addition into the example from web.)
function valid_email_address($mail = ''){
if( (preg_match('/(@.*@)Ś(\.\.)Ś(@\.)Ś(\.@)Ś(^\.)/', $mail)) ||
(preg_match('/^.+\@(\[?)[a-zA-Z0-9\-\.]+\.([a-zA-Z]{2,3}Ś[0-9]{1,3})(\]?)$/',$mail))
) {
$host = explode('@', $mail);
if(checkdnsrr($host[1].'.', 'MX')){
echo "<p>MX record is found!</p>";
return true;
}
if(checkdnsrr($host[1].'.', 'A')){
echo "<p>A record is found!</p>";
return true;
}
if(checkdnsrr($host[1].'.', 'CNAME')){
echo "<p>CNAME record is found</p>";
} return true;
}
echo "<p>No records is found!</p>";
return false;
}
Karl
http://us3.php.net/manual/en/function.checkdnsrr.php
--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
jstu...@attglobal.net
==================