如何将标记聚合而不与Google地图重叠? [英] How can I cluster markers without overlap with google maps?

查看:89
本文介绍了如何将标记聚合而不与Google地图重叠?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我目前在我的谷歌地图上聚集了数百个标记。
许多标记都基于地理编码地址,有时只能解析到城市级别。通常情况下,我最终会说出几百个地址,例如在纽约市的中间地区。



我了解 Marker Clustering 在谷歌地图中,​​但是当所有的标记都具有相同的经度时,你无法点击每个标记,并弹出一个弹出窗口。



如何在放大时以这种方式管理这些标记,您仍然可以知道有多少标记,并仍然点击它们? noreferrer> OverlappingMarkerSpiderfier



请参阅这篇文章将它与MarkerClusterer集成在一起


I am currently clustering hundreds of markers on my google maps. Many of the markers are based on geo-coded addresses, which at times only resolve to the city level. Normally i will end up with lets say a few hundred addresses all with the same lat lon for example in the middle of New York City.

I know about the Marker Clustering in google maps, however when all the markers have the same lat long, you loose the ability to click on each marker, and bring up a popup.

How can I manage these markers in such a way when you zoom in you can still tell how many markers there are, and still click on them?

解决方案

Look at the OverlappingMarkerSpiderfier

See this post on integrating it with MarkerClusterer

这篇关于如何将标记聚合而不与Google地图重叠?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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