source: trunk/Utilities/MaxMindGeoLite/Script/LazyTest.js @ 48

Last change on this file since 48 was 48, checked in by roman, 12 years ago
File size: 642 bytes
Line 
1function EchoLocation(address, location) {
2  if(location == null) {
3    WScript.Echo(address + ": " + "null");
4    return;
5  }
6  WScript.Echo(address + ": " + location.City + ", " + location.Country + "; " + location.Latitude + ", " + location.Longitude);
7}
8
9locations = new ActiveXObject("AlaxInfo.MaxMindGeoLite.LazyLocations");
10
11for(; ; ) {
12  if(locations.Initialized)
13    break;
14  WScript.Echo("Initializing...");
15  //EchoLocation("alax.info", locations.Item("alax.info"));
16  WScript.Sleep(5000);
17}
18
19EchoLocation("alax.info", locations.Item("alax.info"));
20EchoLocation("luxriot.com", locations.Item("luxriot.com"));
21
Note: See TracBrowser for help on using the repository browser.