My situation is that I'm dealing with a *lot* of markers and MarkerManager.js was not speedy enough. Using kml files is much more efficient. In the code below you'll see that different kml files are loaded according to the map's zoom level. Everything works great. However, I can't remove the kml layer once it's been applied, which is necessary to duplicate MarkerManager's functionality.
Here's the reference page for geoXML3: http://code.google.com/p/geoxml3/wiki/ParserReference Thanks a lot for the help. function getSystemFile() { switch (myMap.getZoom()) { case (MIN_ZOOM + 1): system_file = '3025-2.xml'; break; case (MIN_ZOOM + 2): system_file = '3025-3.xml'; break; case (MIN_ZOOM + 3): system_file = '3025-4.xml'; break; default: system_file = '3025-1.xml'; } return system_file; } function initialize() { ...yada yada... var myParser = new geoXML3.parser({ createMarker: addMyMarker, map: myMap, processStyles: true, singleInfoWindow: true, zoom: false }); myParser.parse(getSystemFile()); google.maps.event.addListener(myMap, 'zoom_changed', function() { myParser.parse(getSystemFile()); }); function addMyMarker(placemark) { myParser.createMarker(placemark); } } On Aug 13, 11:39 am, Rossko <[email protected]> wrote: > > Hide markers: > > geoXml.hideDocument (geoXml.docs); > > > Do you have any ideas? > > Guessing, geoXml would need to be in scope when you call that. Any > error reported? > Best approach, as always, show us the patient - > http://groups.google.com/group/google-maps-js-api-v3/t/2b3f101fd509919e -- You received this message because you are subscribed to the Google Groups "Google Maps JavaScript API v3" 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-js-api-v3?hl=en.
