Reputation: 33
I hope you can help me with this weird problem I am having. First a bit of explanation.
I am coding a webapplication in php/javascript where you can create and save placemarks, which is then shown on a google earth globe on the website. In my application I have a search field that simply takes an address or city name.
Now this search functionality was working perfectly until about a week ago, and then it simply stopped working. First I thought I had done something, but when I go here: http://earth-api-samples.googlecode.com/svn/trunk/demos/chinasyndrome/index.html and try to search for an address, its the same problem. Nothing happens.
My javascript that does the search looks like this:
geocoder = new google.maps.ClientGeocoder();
function submitLocationMyWorld() {
var address = el('searchByAddress').value;
geocoder.getLatLng(
address,
function(point) {
if (point && geMyWorldMap3D != null)
var la = geMyWorldMap3D.createLookAt('');
la.set(point.y, point.x, 0, geMyWorldMap3D.ALTITUDE_RELATIVE_TO_GROUND,
100, 0, 1000000);
geMyWorldMap3D.getView().setAbstractView(la);
}
);
}
Any help would be greatly appreciated! thx
Upvotes: 0
Views: 236
Reputation: 48019
I believe the geocoder comes from the V2 version of the Google Maps JavaScript API. That API has been deprecated for a while and was turned down recently.
I found how to migrate to V3, and, specific to your geocoding problem, how to get the lat/lon using the V3 API.
Upvotes: 1