Try something like this.
But place this code inside the load() to make sure that the google namespace
is loaded when this code is executed.
var iconSize = new google.maps.Size(32, 32);
var iconAnchor = new google.maps.Point(16, 32);
var shadowSize = new google.maps.Size(37, 34);
var shadowAnchor = new google.maps.Point(9, 34);
var shadow = new google.maps.MarkerImage('
http://www.celltreesinc.com/maps/icons/shadow.png', shadowSize, null,
shadowAnchor);
var customIcons = {
1: {icon: new google.maps.MarkerImage('
http://www.celltreesinc.com/maps/icons/purple-dot.png', iconSize, null,
iconAnchor),
shadow: shadow},
2: {icon: new google.maps.MarkerImage('
http://www.celltreesinc.com/maps/icons/red-dot.png', iconSize, null,
iconAnchor),
shadow: shadow},
3: {icon: new google.maps.MarkerImage('
http://www.celltreesinc.com/maps/icons/yellow-dot.png', iconSize, null,
iconAnchor),
shadow: shadow},
4: {icon: new google.maps.MarkerImage('
http://www.celltreesinc.com/maps/icons/green-dot.png', iconSize, null,
iconAnchor),
shadow: shadow},
5: {icon: new google.maps.MarkerImage('
http://www.celltreesinc.com/maps/icons/blue-dot.png', iconSize, null,
iconAnchor),
shadow: shadow},
6: {icon: new google.maps.MarkerImage('
http://www.celltreesinc.com/maps/icons/orange-dot.png', iconSize, null,
iconAnchor),
shadow: shadow},
7: {icon: new google.maps.MarkerImage('
http://www.celltreesinc.com/maps/icons/white-dot.png', iconSize, null,
iconAnchor),
shadow: shadow}
};
Marc
--
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.