google maps - kmllayer overlay markers? -
Sorry the noob question, but ... I'm adding a km lost layer to my GMAP. Kml is on my webserver and the new Google Map is being brought. I get the default blue icon so far so good, but I want a customer icon and ultimately the ability to change the style based on an event later everything indicates this method.
Var marker = new google.maps.marker ({status: new google.maps.LatLng (56.8848, 14.7730), map: map, title: 'my workplace', clickable: wrong, icon: 'http: // google -maps-icons.googlecode.com/files/factory.png '}); It seems that it only controls the marker determined by the wave length. In other words only one point
How do I create a custom marker for all my sites? Define within km.
Specify an icon style:
& lt; Style id = "mm_orange_hd2" & gt; & Lt; IconStyle & gt; & Lt; Symbols & gt; & Lt; Href & gt; Http: //missouristate.info/images/2010/homecoming/mm_orange.png< / Href & gt; & Lt; / Symbol & gt; & Lt; Hotspot x = "20" y = "2" xunits = "pixel" yunits = "pixels" /> & Lt; / IconStyle & gt; & Lt; / Style & gt; References said style:
& lt; Placemark id = "id1" & gt; & Lt; Name & gt; Crosstown Barbecue & lt; / Name & gt; & Lt; StyleUrl & gt; # Mm_orange_hd2 & lt; / StyleUrl & gt; & Lt; Point & gt; & Lt; Coordinate & gt; -93.272,37.2278,0 & lt; / Coordinate & gt; & Lt; / Point & gt; & Lt; / Placemark & gt;
Keep in mind that you must add random data to your km list url to prevent map servers from caching it.
Comments
Post a Comment