Google Maps API v3 - GIcon is not defined -


i know issues v2 v3 can here fix it?
gicon not supported v3?

// google-map icon object var gmapicon = new gicon(g_default_icon); //change new google.maps.markerimage();??? // icon exist if ( mapelements[lmapelementindex]['icon'].tostring().length > 0) {     gmapicon.image = html_entity_decode(mapelements[lmapelementindex]['icon']);     gmapicon.shadow = "";     iconheight = mapelements[lmapelementindex]['iconheight'];     iconwidth = mapelements[lmapelementindex]['iconwidth'];     gmapicon.iconsize = new gsize(iconwidth,iconheight);     gmapicon.iconanchor = new gpoint(0,0);     gmapicon.infowindowanchor = new gpoint(15,10); }     var markeroptions = {          icon: gmapicon //change image?       };     var marker = new google.maps.marker(point,markeroptions); 

found here https://developers.google.com/maps/documentation/javascript/overlays?hl=de-de#simpleicons

thanks or tips!

gicon not supported version 3, , not appear in documentation link to.

  var image = 'beachflag.png';   var mylatlng = new google.maps.latlng(-33.890542, 151.274856);   var beachmarker = new google.maps.marker({       position: mylatlng,       map: map,       icon: image   }); 

you can specify image use directly, don't need helper object version 2's gicon. however, if want non-standard sizes etc need use markerimage object described in documentation @ https://developers.google.com/maps/documentation/javascript/overlays?hl=de-de#complexicons

(version 2's gicon has equivalent optional markerimage in version 3)


Comments

Popular posts from this blog

java - Play! framework 2.0: How to display multiple image? -

gmail - Is there any documentation for read-only access to the Google Contacts API? -

php - Controller/JToolBar not working in Joomla 2.5 -