Scott
Scott

Reputation: 3485

Combine map points - Google map API

I have a javascript Google Map that starts with a full world view and has a lot of clustered points in certain areas. Because the points on the map are so close it just looks like a lot of overlapping pins and makes it impossible to click on any of them accepted the top pin. What I'd like to do is combine all of the clustered points into one point that could be clicked for a list of all of the combined locations when viewing the whole map or a large section of it and spread the points back out when zoomed into that area of the map. I've had a good look around and can't seem to find any way to do it, am I missing something or is there a workaround that would allow this?

Thanks for all of your help!

Upvotes: 4

Views: 5510

Answers (2)

MisterIsaak
MisterIsaak

Reputation: 3922

I use Clusterer and have been happy with it. Fairly simple and straight forward

http://google-maps-utility-library-v3.googlecode.com/svn/trunk/markerclusterer/docs/examples.html

Here is another option that I found afterwards that may be worth a look into as well

http://gmap3.net/examples/clustering.html

Update:

More recent Google documentation, some good information!

https://developers.google.com/maps/articles/toomanymarkers

Upvotes: 2

Sarah Haskins
Sarah Haskins

Reputation: 1395

There is a really good write-up of various options here: http://www.svennerberg.com/2009/01/handling-large-amounts-of-markers-in-google-maps/

It includes MarkerManager, Clusterer, ClusterMarkup, and MarkerClusterer.

Upvotes: 7

Related Questions