开发者

Google maps static api - Marker doesn't show up

开发者 https://www.devze.com 2023-01-12 15:29 出处:网络
I got a static map link using this wizard http://gmaps-samples.googlecode.com/svn/trunk/simplewizard/makestaticmap.html and the marker is on the image, but when i put this link into my website, the ma

I got a static map link using this wizard http://gmaps-samples.googlecode.com/svn/trunk/simplewizard/makestaticmap.html and the marker is on the image, but when i put this link into my website, the marker doesn't show up.

Here is the website where i'm trying to view the map. I see the map, but no marker. http:/开发者_高级运维/church.allthingswebdesign.com

I just have the link in an image tag like this

<img id="map" src="http://maps.google.com/staticmap?center=43.963415,-92.460594&zoom=14&markers=Comfort+Suites,+4141+Maine+Ave+SE,+Rochester,+MN++55904&size=300x400&sensor=TRUE_OR_FALSE&key=ABQIAAAA6-Rq-t8XwsqXeXws3DleLBSI_7XewNJfovQwsmZjGMbTG7rp6BQaj3bwm-gy7nGQPyWKPTd3zPtcVA" alt="Map" />

Why doesn't the marker show up on my website?


Ok, one thing to change - where it says TRUE_OR_FALSE in the url try changing it to false (all lower case).

If I browse directly to the url of the image provided, I don't see a marker so I suspect it's a problem with the wizard rather than your site.

Try this:

<img src="https://maps.google.com/maps/api/staticmap?center=43.962072,-92.456297&zoom=13&markers=43.962072,-92.456297&size=300x400&sensor=false&key=ABQIAAAA6-Rq-t8XwsqXeXws3DleLBSI_7XewNJfovQwsmZjGMbTG7rp6BQaj3bwm-gy7nGQPyWKPTd3zPtcVA">

For details on the sensor parameter, see here

0

精彩评论

暂无评论...
验证码 换一张
取 消