Hello,

I'm French and Im trying to find how to geocode adress into lat.long directly in Gmap.
I have in my nodes: street, city, postal code and country but i still need to use the gmap map just below to enter lat and long. Is there a solution to just enter the adress and with or without any action, having the node placed on the map directly?

I have been searching but I do not understand what it is written concerning this problem.

Thank you very much and congratulations for your work.

Merci :)

Comments

TimDavies’s picture

As far as I understand - the Location Module (http://drupal.org/project/location) should be the one to take care of geocoding.

It doesn't have very good support for non US / Canadian addresses, as the datasets that can look-up latitude and longitude from address for other countries are often not available.

The actual geocoding work is done by the country specific files in 'modules/location/supported/*'

So:
-If someone else has written the relevant geocoding functions for France, you'll need to try and get hold of their location.fr.inc file and make use of that

-If not - and you know of a suitable dataset or web-service for geocoding for France - you could try creating a location.fr.inc file (look at location.us.inc for a model...)

-If you don't need amazing levels of accuracy - I've got a patch for location at: http://drupal.org/node/75459#comment-216146 which implements a 'generic geocoder fallback' - meaning where not specific country level geocoder is available, or where no results are returned, the system will turn to Geonames.org which usually manages to provide some form of geocoding - although often city or town level accuracy rather than street-level accuracy.

Tim

bdragon’s picture

Project: GMap Module » Location

Moving to Location.

bdragon’s picture

Component: Code » Data update

Changing component to Data update.

yesct’s picture

yesct’s picture

Status: Active » Closed (duplicate)

opps forgot to change the status.