This is a static archive of our old OSM Help Site. Please post any new questions and answers at community.openstreetmap.org.

embedded maps not working

1

I have a website www.holidaysbycycle.com and use OpenStreetMap to embed on the site using a html code. This has worked fine until recently when the maps just show as an empty grey box (still with zoom in/out). Are the embedded codes working? Any ideas? I have used different browsers.

Many thanks Tom

asked 13 Sep '16, 07:47

tombomb1's gravatar image

tombomb1
26223
accept rate: 0%

edited 14 Sep '16, 21:59

aseerel4c26's gravatar image

aseerel4c26 ♦
32.6k18248554

2

Specifically it's the links to the cycling and transport layers on your site that don't work for me. Taking an example link location from your site:

http://www.openstreetmap.org/export/embed.html?bbox=4.821281433105468%2C52.338171059294034%2C4.978179931640624%2C52.40262833871028&layer=cyclemap

If I omit the "&layer=cyclemap" off the end it works as an embedded link (but obviously shows the "wrong" map).

(13 Sep '16, 08:24) SomeoneElse ♦

2 Answers:

2

There appears to be a bug in the openstreetmap-website code, where it uses the API Keys correctly in the maps in most places they are used on openstreetmap.org, but not in the embed maps, which uses its own javascript.

I've opened an issue and hopefully it'll be fixed.

answered 21 Sep '16, 19:22

Andy%20Allan's gravatar image

Andy Allan
12.5k23128153
accept rate: 28%

That's great Andy - thanks for your feedback

Tom

(21 Sep '16, 20:37) tombomb1

One of the maintainers has fixed the problem, and it's now deployed. You shouldn't need to change anything to see the fix, just refresh.

(21 Sep '16, 21:59) Andy Allan

1

answered 14 Sep '16, 22:34

yvecai's gravatar image

yvecai
1.5k1226
accept rate: 9%

1

Indeed. OSM also uses an API key for displaying the cycle layer.

(15 Sep '16, 07:54) scai ♦