comparison geoiptest.php @ 42:3f400072bf14

merge, involved ediff3 wrt getAmazonInfo.php
author Charlie Root
date Sat, 05 Jan 2019 06:21:12 -0500
parents 1bb0bc3d306a
children
comparison
equal deleted inserted replaced
41:0578c6e438d3 42:3f400072bf14
1 <html> 1 <html>
2 <body> 2 <body>
3 <?php 3 <?php
4 if (isset($_SERVER["GEOIP_COUNTRY_NAME"])) {
4 $country_name = $_SERVER["GEOIP_COUNTRY_NAME"]; 5 $country_name = $_SERVER["GEOIP_COUNTRY_NAME"];
5 print "Country: " . $country_name; 6 }
7 else {
8 $country_name = $_SERVER["REDIRECT_GEOIP_COUNTRY_NAME"];
9 }
10 if (isset($_SERVER["GEOIP_COUNTRY_CODE"])) {
11 $country_code = $_SERVER["GEOIP_COUNTRY_CODE"];
12 }
13 else {
14 $country_code = $_SERVER["REDIRECT_GEOIP_COUNTRY_CODE"];
15 }
16 print "Country: $country_name , code: $country_code";
6 ?> 17 ?>
7 </body> 18 </body>
8 </html> 19 </html>