Page 1 of 1

API not outputting the same as front page

PostPosted: Thu Feb 16, 2006 10:44 pm
by debugdom
Hi-

First i'd like to say, thanks for the super rad database.

When I goto the front page and put in a IP address such as 217.111.22.98 it returns:

(guessed) Oberursel, GERMANY
IP found in 0.022 seconds

however if the same IP is entered into the api it returns:

This is the Hostip Lookup Service hostip inapplicable (Unknown city) GERMANY DE

is there anyway that i can get the API to return a 'guessed' value?

thanks in advance

dom

p.s i've written a php script that takes the users ip and then returns their current weather if anyone wants a copy give me a pm.

Re: API not outputting the same as front page

PostPosted: Mon Feb 20, 2006 7:16 pm
by bfolkens
debugdom wrote:Hi-

First i'd like to say, thanks for the super rad database.

When I goto the front page and put in a IP address such as 217.111.22.98 it returns:

(guessed) Oberursel, GERMANY
IP found in 0.022 seconds

however if the same IP is entered into the api it returns:

This is the Hostip Lookup Service hostip inapplicable (Unknown city) GERMANY DE

is there anyway that i can get the API to return a 'guessed' value?

thanks in advance

dom

p.s i've written a php script that takes the users ip and then returns their current weather if anyone wants a copy give me a pm.


Remember, the lookups on the front page use the guessing algorithm - whereas in the api you have the option of using that or not... If the city is unknown but the country is correct - it'll be explicit and not guess.

PostPosted: Mon Feb 20, 2006 8:08 pm
by debugdom
Thanks, I actually found an old post that spoke of the same issue and I have changed my code accordingly.