Accesing the Marker Library as a Sprite

23 views
Skip to first unread message

neil

unread,
Apr 28, 2011, 10:43:23 AM4/28/11
to Google Maps EZ
With the large number of markers, each referenced by a copy of the
image, in my web page I made the library of marker images into a
sprite and now use slices to display the image in the html. This
significantly reduced the number of calls made to load and speeded
things up no end.
Taking it a step forward I thought of replacing the marker icons
actually showing on the map itself in the same manner. The script
currently refers to the 'getElementsByTagName' to build up the
required marker.
This where I need help....
As my sprite slices are defined as classes i need to be able to
reference them as such e.g 'getElementsByClassName' (?)

I envisaged the current code in the html e,g,...
<a id="F" title="My House" href="http://maps.google.com/maps?
ll=37.086175,-8.731374&amp;spn=0.002054,0.003433&amp;hl=en">YELLOW F
UPPER</a>
being changed to something like...
<a id="F" title="My House" href="http://maps.google.com/maps?
ll=37.086175,-8.731374&amp;spn=0.002054,0.003433&amp;hl=en"
class="YELLOW-F-UPPER">&nbsp;</a>

Is this possible? Can anyone help (to at least get me started) in
changing the GMAPEZ script to do this.

Maybe this is being ambitious but having used GMAPEZ for years I'm
loathe to change.
Thanks

If anybody wants the sprite(s) just let me know.

Pavel Kolařík

unread,
Apr 28, 2011, 3:09:00 PM4/28/11
to google-...@googlegroups.com
i want :)
Reply all
Reply to author
Forward
0 new messages