diff options
Diffstat (limited to 'src')
-rwxr-xr-x | src/usr/local/www/diag_dns.php | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/src/usr/local/www/diag_dns.php b/src/usr/local/www/diag_dns.php index dfbbd53..4284993 100755 --- a/src/usr/local/www/diag_dns.php +++ b/src/usr/local/www/diag_dns.php @@ -192,10 +192,13 @@ if ($_POST) { if (!$input_errors) { if (is_ipaddr($host)) { $type = "ip"; - $resolved = gethostbyaddr($host); + $resolvedptr = gethostbyaddr($host); $ipaddr = $host; - if ($host != $resolved) { - $hostname = $resolved; + if ($host != $resolvedptr) { + $tmpresolved = array(); + $tmpresolved['type'] = "PTR"; + $tmpresolved['data'] = $resolvedptr; + $resolved[] = $tmpresolved; } } elseif (is_hostname($host)) { $type = "hostname"; |