Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
Next revision Both sides next revision
litespeed_wiki:lslb:geoip [2019/08/27 19:17]
Jackson Zhang
litespeed_wiki:lslb:geoip [2019/08/27 19:22]
Jackson Zhang
Line 4: Line 4:
 To setup and enable GeoIP on LiteSpeed ADC, you will need to choose one database, download and install the database to a directory, setup the database path in ADC Admin, ''​Enable GeoLocation Lookup''​ should set to ''​Yes'',​ then set rewrite rules in virtual host rewrite tab and finally run some tests. ​ To setup and enable GeoIP on LiteSpeed ADC, you will need to choose one database, download and install the database to a directory, setup the database path in ADC Admin, ''​Enable GeoLocation Lookup''​ should set to ''​Yes'',​ then set rewrite rules in virtual host rewrite tab and finally run some tests. ​
  
-{{:​litespeed_wiki:​lslb:​adc-geoip-1.png?800|}}+{{:​litespeed_wiki:​lslb:​adc-geoip-11.png?800|}}
  
 ===== set ''​Enable GeoLocation Lookup''​ to ''​Yes''​ ===== ===== set ''​Enable GeoLocation Lookup''​ to ''​Yes''​ =====
Line 81: Line 81:
 {{ :​litespeed_wiki:​cache:​common:​litespeed-geoip2-variables-e1.png?​800 |}} {{ :​litespeed_wiki:​cache:​common:​litespeed-geoip2-variables-e1.png?​800 |}}
  
-It will show on the ''​phpinfo.php''​ page as: +
-   ​_SERVER["​MyTest_COUNTRY_CODE"​] ​ US+
 ''​US''​ will be replaced by the country code you are visiting from, such as ''​SG''​ or others. ''​US''​ will be replaced by the country code you are visiting from, such as ''​SG''​ or others.
  
Line 89: Line 88:
   MyTest2_COUNTRY_CODE COUNTRY_DB_20190402/​country/​iso_code   MyTest2_COUNTRY_CODE COUNTRY_DB_20190402/​country/​iso_code
 {{ :​litespeed_wiki:​cache:​common:​litespeed-geoip2-variables-e2.png?​800 |}}  ​ {{ :​litespeed_wiki:​cache:​common:​litespeed-geoip2-variables-e2.png?​800 |}}  ​
-It will show on the ''​phpinfo.php''​ page as: 
-  _SERVER["​MyTest2_COUNTRY_CODE"​] US 
  
 === Example 4 === === Example 4 ===
Line 106: Line 103:
 {{ :​litespeed_wiki:​cache:​common:​litespeed-geoip2-variables-e4-1.png?​600 |}} {{ :​litespeed_wiki:​cache:​common:​litespeed-geoip2-variables-e4-1.png?​600 |}}
  
-It will show on the ''​phpinfo.php''​ page as: 
-  _SERVER["​HTTP_GEOIP_CITY"​] Montville 
-  _SERVER["​HTTP_GEOIP_POSTAL_CODE"​] 07045 
-  _SERVER["​HTTP_GEOIP_CITY_CONTINENT_CODE"​] NA 
-  _SERVER["​HTTP_GEOIP_CITY_COUNTRY_CODE"​] US 
-  _SERVER["​HTTP_GEOIP_CITY_COUNTRY_NAME"​] United States 
-  _SERVER["​HTTP_GEOIP_REGION"​] NJ 
-  _SERVER["​HTTP_GEOIP_LATITUDE"​] 40.90490 
-  _SERVER["​HTTP_GEOIP_LONGITUDE"​] -74.36460 
- 
-{{ :​litespeed_wiki:​cache:​common:​litespeed-geoip2-variables-e4-2.png?​400 |}} 
  
 === Setup Database File Path === === Setup Database File Path ===
  • Admin
  • Last modified: 2020/11/18 15:43
  • by Lisa Clarke