Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Google Maps Javascript API custom marker number

I am using custom images for my markers using google maps javascript api V3 and I was wondering if anyone knows how to super impose a number on top of those. I have a box image and I need to dynamically place a number in the box. I don't know if there is a style way of doing this or if someone can tell me how to do it via javascript.

like image 772
Red Avatar asked Feb 03 '26 08:02

Red


1 Answers

You can use maps utility library ( http://code.google.com/p/google-maps-utility-library-v3/wiki/Libraries ). RichMarker & styledMarker (scroll down the page) are probably most useful to you.

Option 2 - you can roll your own implementing overlay class (a bit of work required). Example is here http://gmaps-samples-v3.googlecode.com/svn/trunk/overlayview/custommarker.html

Option 3 - (more tedious) is to create custom marker images with numbers on them.

like image 170
Michal Avatar answered Feb 05 '26 20:02

Michal



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!