Drupal gmap not showing markers

Setting up Gmap and Location in Drupal is pretty easy. If you’re having trouble getting started there are a bunch of Gmaps Drupal tutorials out there, including this one at Drupal Therapy.

Using Addresses Not Coordinates

But there’s a bit of a gotcha that they don’t tell you about. I created a new content type with location information and was able to create content with addresses. After creating a new page, I would see a “Google Map” link that would show the location on a Google map so I thought everything was working fine. But when I went to view the “Node Location” map there were no markers. Why?

Solution

If you are entering addresses and NOT coordinates, you need to tell the module that you want to translate from one to the other when you display the map. So go to:
/admin/settings/location/geocoding
and enable geocoding for every country relevant to your application. You’ll need to recreate your content for the changes to take effect. After creating content with location information you should see the coordinates listed.

Leave a Reply

Your email address will not be published. Required fields are marked *