谷歌地图中的几个亮点嵌入API [英] Several highlights in google maps embed API

查看:214
本文介绍了谷歌地图中的几个亮点嵌入API的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想在iframe中添加几个使用Google地图的嵌入API的高亮地点,如下所示:

code>< iframe src =https://www.google.com/maps/embed/v1/place?key=AIzaSyBstlDO5AXkMg6xOjrkTJliYabsODR2vYA&q=Harvard+University,Parque+explorawidth =100%height =500frameborder =0style =border:0allowfullscreen>< / iframe>

如何将几个位置添加到q参数?



Thx!

解决方案

您必须使用。


I would like to add several highlight places using the Embed API of Google Maps in an Iframe like this:

<iframe src="https://www.google.com/maps/embed/v1/place?key=AIzaSyBstlDO5AXkMg6xOjrkTJliYabsODR2vYA&q=Harvard+University,Parque+explora" width="100%" height="500" frameborder="0" style="border:0" allowfullscreen></iframe>

How can I add several locations to the q parameter?

Thx!

解决方案

You would have to use mymap, or the Google Maps API to do it. Embed API does not support multiple markers.

For using My Map, you need to set your maps to public before you can embed it onto your site.

To generate the embed url, it is under the 3... next to the share button

If you decided to do it with the API, you might want to reference to the Markers part of the documentation.

这篇关于谷歌地图中的几个亮点嵌入API的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆