nslookup - geographic location

Discussion in 'Classic ASP' started by joelnet, Jul 21, 2006.

Thread Status:
Threads that have been inactive for 5 years or longer are closed to further replies. Please start a new thread.
  1. I don't believe we have any components installed that will let you do an nslookup in classic asp.



    Joel Thoms
    DiscountASP.NET
    http://www.DiscountASP.NET
     
  2. Bruce

    Bruce DiscountASP.NET Staff

  3. I had a look to the components of nsoftware, but I believe reverse DNS is not possible, is it? You can only do a .query for a DNS name and then retrieve the IP address, but not the opposite...


    If you try in DOS box : nslookup [your-ip-address] , then you will see the result that I would like to have in a ASP page ... any other idea?


    (by the way, there are online webpages available that do the lookup for free, and it would be possible to retrieve THAT result with XMLHTTP, but it would be nicer not to be dependant on another service)


    thanks
     
  4. Bruce

    Bruce DiscountASP.NET Staff

  5. I would like to determine the geographical location of any internet user that accesses my site. So for example, people from Brasil will automatically look at information from Brasil, and people from specific countries in Europe get other information.

    My first try to do this, would be to get the reverse DNS of the IP address, like a nslookup 123.123.123.123 -> domain.country or domain.com/gov/org etc (this is the IP address given by the provider to the internet user, the provider can be anything)

    In the case of a country, such as br, nl, uk, fr, etc I can determine the correct page to be shown.

    My questions:
    * how can I do this nslookup using classic ASP ? Is there any component available on discountasp ?
    * what to do in the case the provider is a .com (.org and .gov are unlikely to happen I think)

    I tried this : http://www.asp101.com/articles/jason/reversedns/default.asp but it does not work (also not when removing "option explicit" :) ) It is because wscript is not an allowed component.

    Any help is greatly apreciated.
     
  6. wwv

    wwv

  7. I too need to resolve the users State within the US. Does anyone have knowledge of this besides just posting links?


    Mini
     
  8. wwv

    wwv

    Hi Mini,</o:p>
    </o:p>
    </o:p>
    Maybe you find some useful information on my Web Services:</o:p>
    http://www.wwv-it.com/WebServicesNet/ServicesNet.aspx</o:p>
    </o:p>
    Category: <st1:country-region><st1:place>USA and <st1:country-region><st1:place>Canada Services</o:p>
    </o:p>
    If yes, I would send you useful code.</o:p>
    </o:p>
    Regards,</o:p>
    </o:p>
    Valentin</o:p>
    www.wwv-it.eu</o:p>
     
  9. Not interested in links just information......... But thanks


    Mini
     
  10. wwv

    wwv

    Hi Mini,</o:p>
    </o:p>
    That is not a simply link. My site uses links to Web Services providers to pick the necessary data. It is based on the SOA technology.</o:p>
    So, either you use a Web Service or you have to create a database / tables and populate with data or a XML file containing the <st1:country-region><st1:place>USA states. In Google you can find a lot of sites about the <st1:country-region><st1:place>USA states.</o:p>
    </o:p>
    Regards </o:p>
    </o:p>
    Valentin</o:p>
     
Thread Status:
Threads that have been inactive for 5 years or longer are closed to further replies. Please start a new thread.

Share This Page