diff geoiptest.php @ 20:7679346abfdb

get code and use it
author Charlie Root
date Thu, 25 Oct 2018 09:40:25 -0400
parents 093e42d5a874
children 1bb0bc3d306a
line wrap: on
line diff
--- a/geoiptest.php	Thu Aug 30 17:18:12 2018 -0400
+++ b/geoiptest.php	Thu Oct 25 09:40:25 2018 -0400
@@ -2,7 +2,8 @@
 <body>
 <?php
 $country_name = $_SERVER["GEOIP_COUNTRY_NAME"];
-print "Country: " . $country_name;
+$country_code = $_SERVER["GEOIP_COUNTRY_CODE"];
+print "Country: $country_name , code: $country_code";
 ?>
 </body>
 </html>