Link to home
Start Free TrialLog in
Avatar of shobinsun
shobinsunFlag for India

asked on

Google map Question

Hi,

I have a simple google map application to find the coordinates when typing the address in a text field.

Its working well in most of the cases.

But I am facing problem that when i type 'net use' in the text field , its not giving the coordinates ( address is not found.) I tried the 'net use' address in the "maps.google.be" site and I got the addresses.

What might be the problem?

I thought that may be the space used between the 'net' and 'use' words, but I got info about the place "Den haag" in my application as well as in the google site directly.

So please help me.

Thanks in advance.
google.txt
Avatar of profya
profya
Flag of Sudan image

I don't think there is a problem with that, your address 'net use' returns 602 status code, the same as if you enter 'dsadasdsadasdasdasdasda', it means that it does not find it. You can test it using Google sample at: http/code.google.com/apis/maps/documentation/examples/geocoding-simple.html
I think your problem is that Belgium does not exist.  See here:
http://zapatopi.net/belgium/

;-)

Now having said that, what address or geocode did you expect "net use" to produce?
Avatar of shobinsun

ASKER

Hi ,

Thanks for your quick reply.

I expect the solution that is given by:

http://maps.google.be/

when entering "net use".

Here I am attaching the screen shot I am getting with google map directly and what i am expecting.

Thanks.

Screenshot.png
This is interesting.  I tried URL http://maps.google.be/maps and entered "net use" - this is what it gave back for the link, and it is faithful to the locations near Antwerp.

http://maps.google.be/maps?f=q&source=s_q&hl=nl&geocode=&q=net+use&sll=50.805935,4.432983&sspn=5.075643,14.666748&ie=UTF8&hq=net+use&hnear=&z=12
Hi,

This is an application on the web for getting latitude and longitude values:

http://seifi.org/wp-content/uploads/2005/04/googlemapsll.php?q=net+use

When typing "net use", I got the values.

And tried this:

http://maps.google.be/maps/geo?q=net%20use

Error code getting.

So what to do?

Please give me some advice.

Thanks.
ASKER CERTIFIED SOLUTION
Avatar of Ray Paseur
Ray Paseur
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Hi,

Thanks for your reply and code. I tried your code and I got the result for "net use" as:

GOOGLE SimpleGeoCoder Object
(
    [location] =>
    [address] =>
    [city] => Net, Hindoli 323023
    [state] => India
    [zip] =>
    [yfp:private] =>
    [yahooUrl:private] =>
    [yahooResponse:private] =>
    [ydata:private] =>
    [gfp:private] =>
    [googleUrl:private] =>
    [googleResponse:private] =>
    [gdata:private] =>
    [latitude] => 21.0596718
    [longitude] => 73.0677295
    [precision] => 6
    [warning] =>
    [geocoder] => Google
    [precis:private] => zip
)


Its not the address what I expected.

And also I created a new entry ("zzzzzzzz")in google map and tried to get the geocode values via :

http://maps.google.com/maps/geo?q=zzzzzzzz

and getting the result as:

{
  "name": "zzzzzzzz",
  "Status": {
    "code": 602,
    "request": "geocode"
  }
}


So I think when creating the locations in the google map, its not creating the geocode values.

Then how can we create that?

Any idea about that?

Very interesting !!

Thanks.

"And also I created a new entry ("zzzzzzzz")in google map and tried to get the geocode... So I think when creating the locations in the google map, its not creating the geocode values."

Not sure I understand.  How would Google come to understand that this had meaning as an address?
http://maps.google.com/maps/geo?q=zzzzzzzz
Hi,

Can you create  a new location with a valid address in the google map and try to get the geocode values, please.

I created "zzzzzzzz" named location ad address is : zzzzzz xxxxxx yyyyyy zzzzzz xxxxxx yyyyyy

But when i searched in the google maps, it gives me the result .

See the screen shot attached.

Then Why didnt get the geocode values?



Screenshot-2.png
Check the fields that are shown in the red circle.  This is where you may be able to find the LAT/LON pair.
shobinsun.png
HI,

I can see the LAT and LONG values when mouse over the " Link ".

But How can we get the values using php code?

Can you give me a simple example?

Thanks.
I'm not understanding something here.  Did you create the pointer that we see on the map pictures?  If so, wouldn't you know the LAT/LON pair?  It seems to me that getting the geocode data from Google is backwards - you would be telling Google the LAT/LON pair, right?
Thank you very much..!!!!