How to Fix Missing MarkeClusterer Icons for Drupal Gmap Module

| Drupal Development | 0 seen

I have been using Drupal + Mapping for years already. My most favorite combination Location + Gmap module for entering and displaying location info. 

Recently I did upgrade for Gmap module for this blog and things went wrong - customized province names disappeared and... Marker Clusterer icons were gone soon afterwards. My first thoughts were that latest Gmap module have done something wrong, turned out I was wrong. My next idea was it's related to Advanced Aggregation module - again wrong.

Finally the problem as it seems is related to - https://www.drupal.org/node/2734133 - Google has moved its source to github.

The MarkerClusterer library not shows the cluster icons because it has moved to github as it described here.

As it was pointed out by user chrbak on Drupal.

Today I decided finally to get back Marker Clusterer, because without it - it just looks ugly and breaks things apart.

Broken MarkerCluster

Broken Marker Clusterer icons

Above you can see my travel map, unfortunately marker cluster is broken. Let's fix this.

To do that download the library file (markerclusterer.js) and the images folder and put them to thirdparty folder of gmap module.

Now open markercluster.js file and edit following: (line 193)

MarkerClusterer.prototype.MARKER_CLUSTER_IMAGE_PATH_ = '../images/m';

to


MarkerClusterer.prototype.MARKER_CLUSTER_IMAGE_PATH_ = '../sites/all/modules/gmap/thirdparty/images/m';

Save your file, clear Drupal cache and you should be fine:

Working Marker Clusterer icons

Working Marker Clusterer icons