(*e.g. techoism.com)

[insert_php]
if($_POST) {
$domain = trim($_POST[‘_search’]);
echo “

MX Lookup for “.$domain.”

“;
if($domain == ”) {
echo “

Invalid data

“;
} else {
$dataArr = dns_get_record($domain);
echo “

“;
foreach($dataArr as $value) {

if($value[‘type’] == ‘MX’) {
echo ‘

‘;
}

}
echo “

TTLPREFHOST NAME
‘.$value[‘ttl’].’‘.$value[‘pri’].’‘.$value[‘target’].’

“;
}
}
[/insert_php]