0

When I use the map link within a contact details to get a map view of their address, the mapping starts to load but the map image tiles all display the following message:

"as of July 11 2016, direct tile access has been discontinued. etc. etc.".

So I went to the MapQuest site, created a free account, got an API key but don't seem to be able to insert it anywhere in civicrm?

FYI, I'm using openStreet Maps as the provider and Google for Geocoding, therefore no APIkey required (right?).

Should I be able to enter the API key from MapQuest in somewhere?

1
  • Update - I switched to Google and grabbed an API and it works fine. Note that there still seems to eb an issue with the MapQuest though.
    – jkobier
    Aug 17, 2016 at 7:14

2 Answers 2

0

CiviCRM OpenStreet Maps function is pointing to map tiles that are no longer available.

See: https://stackoverflow.com/questions/38315300/mapquest-direct-tile-access-discontinued

1

You can use OpenStreetMap tiles if you replace the tile pointer in this file:

.../templates/CRM/Contact/Form/Task/Map/OpenStreetMaps.tpl

Change this...

    map.addLayer(new OpenLayers.Layer.OSM("MapQuest OSM", [
        "https://otile1-s.mqcdn.com/tiles/1.0.0/map/${z}/${x}/${y}.jpg",
        "https://otile2-s.mqcdn.com/tiles/1.0.0/map/${z}/${x}/${y}.jpg",
        "https://otile3-s.mqcdn.com/tiles/1.0.0/map/${z}/${x}/${y}.jpg",
        "https://otile4-s.mqcdn.com/tiles/1.0.0/map/${z}/${x}/${y}.jpg",
    ], {
        attribution: "<p>Tiles Courtesy of <a href='http://www.mapquest.com/' target='_blank'>MapQuest</a>. Data &copy; <a href='http://www.openstreetmap.org/' target='_blank'>OpenStreetMap</a> contributors.</p>"
    })); 

To this ...

    map.addLayer(new OpenLayers.Layer.OSM("openstreetmap", [
        "https://a.tile.openstreetmap.org/${z}/${x}/${y}.png",
        "https://b.tile.openstreetmap.org/${z}/${x}/${y}.png",
        "https://c.tile.openstreetmap.org/${z}/${x}/${y}.png"
    ], {
        attribution: "<p>Map Courtesy of <a href='http://www.openstreetmap.org/' target='_blank'>OpenStreetMap</a></p>"
    }));

You do want to use https!

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.