Re: Custom Icons Setup
On Oct 12, 2:26 pm, BenB <ben.br...@lavenham-photographic.co.uk>
wrote:
>
> Here's what I've done so far, it works but I don't know how to specify
> which ones use my custom icon:
Look into GMarkerOptions:
var marker = new GMarker(point,{icon:parkingIcon});
To make a generic createMarker function, you could pass the icon to
use as well as the location and html:
function createMarker(point,html,iconToUse) {
...
var marker = new GMarker(point,{icon:iconToUse});
...
}
...
createMarker(point,'Some text',parkingIcon);
createMarker(point,'Some text');
I think the last one should result in the default red marker being
used, but I haven't verified that.
Andrew
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Google Maps API" group.
To post to this group, send email to google-maps-api@googlegroups.com
To unsubscribe from this group, send email to google-maps-api+unsubscribe@googlegroups.com
For more options, visit this group at http://groups.google.com/group/google-maps-api?hl=en
-~----------~----~----~----~------~----~------~--~---
0 Comments:
Post a Comment
Subscribe to Post Comments [Atom]
<< Home