diff options
-rw-r--r-- | en/downloads/debug/index.php | 16 |
1 files changed, 14 insertions, 2 deletions
diff --git a/en/downloads/debug/index.php b/en/downloads/debug/index.php index e5add963b..c93ddfaeb 100644 --- a/en/downloads/debug/index.php +++ b/en/downloads/debug/index.php @@ -1,6 +1,10 @@ <?php $ips = array(); +$functions = array( + 'geoip_country_code_by_name', + 'geoip_continent_code_by_name' +); if (isset($_SERVER['HTTP_X_FORWARDED_FOR']) && $str = $_SERVER['HTTP_X_FORWARDED_FOR']) @@ -12,9 +16,17 @@ if (isset($_SERVER['HTTP_X_FORWARDED_FOR']) else $ips['ip'] = $_SERVER['REMOTE_ADDR']; -echo '<html><body><pre>Testing IP, country, continent', - "\n------------------------------\n\n"; +echo '<html><body>'; +echo '<h3>Testing functions:</h3>'; +echo '<ul>'; +foreach ($functions as $f) { + echo sprintf('<li>%s: %s available</li>', + $f, function_exists($f) ? 'is' : 'is not'); +} +echo '</ul>'; + +echo '<h3>Testing IP, country, continent</h3>'; foreach ($ips as $label => $ip) { echo ' * ', $label, ': ', $ip, ' => '; echo geoip_country_code_by_name($ip), ', '; |