Hi,

I'm having a big issue combining infowindow and Markerercluster. Been
searching and testing extensively but haven't found a solution.

The map works fine as of now but I need to add html content to every
marker. Any idea on how I can do this?

Map: http://tinyurl.com/642c9b8

Code:

    function load() {
      if (GBrowserIsCompatible()) {
        var map = new GMap2(document.getElementById("map"));
        map.addControl(new GLargeMapControl());
        map.setCenter(new GLatLng(59.417138, 8.920898), 8);
                var icon = new GIcon(G_DEFAULT_ICON);
        icon.image = "http://chart.apis.google.com/chart?
cht=mm&chs=24x32&chco=FFFFFF,008CFF,000000&ext=.png";

        GDownloadUrl("genxml.php", function(data) {
          var xml = GXml.parse(data);

                  var markers = [];
          var markers2 =
xml.documentElement.getElementsByTagName("marker");
          for (var i = 0; i < markers2.length; i++) {
            var name = markers2[i].getAttribute("name");
            var kommune = markers2[i].getAttribute("kommune");
                        var latlng = new 
GLatLng(markers2[i].getAttribute("lat"),
markers2[i].getAttribute("lng"));
                var marker = new GMarker(latlng,
{title:markers2[i].getAttribute("vegnavn")});
                        markers.push(marker);
                  }
                var markerCluster = new MarkerClusterer(map, markers);
        });
      }
    }

-- 
You received this message because you are subscribed to the Google Groups 
"Google Maps API V2" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/google-maps-api?hl=en.

Reply via email to