diff --git a/index.php b/index.php
index 2d4ac18..aab8925 100644
--- a/index.php
+++ b/index.php
@@ -50,9 +50,9 @@ function GetIP(string $type)
if (strpos($ip, '.')) break;
}
} else if ('ipv6' == $type)
- $ip = trim(`curl --silent -6 icanhazip.com`);
+ $ip = trim(`dig @resolver1.ipv6-sandbox.opendns.com AAAA myip.opendns.com +short -6`);
else if ('ipv4' == $type)
- $ip = trim(`curl --silent -4 icanhazip.com`);
+ $ip = trim(`dig @resolver4.opendns.com myip.opendns.com +short -4`);
else
$ip = '';
return $ip;
@@ -186,11 +186,16 @@ foreach($showlist as $section) {
echo '
', "\n";
break;
case 'IP':
+ $hasv6 = str_contains(GetCFGValue('ircddb0_host'), 'v6');
+ if (! $hasv6) $hasv6 = str_contains(GetCFGValue('ircddb1_host'), 'v6');
echo 'IP Addresses:
', "\n";
echo '
| Internal | IPV4 | IPV6 |
| ', GetIP('internal'), ' | ', GetIP('ipv4'), ' | ', GetIP('ipv6'), ' |
QnetGateway Dashboard Version 613 Copyright © by Thomas A. Early, N7TAE.
+QnetGateway Dashboard Version 10208 Copyright © by Thomas A. Early, N7TAE.