Search for:
Jump to: 
Your Ad Here
Author Message
 Post subject: Display custom Markers in google Maps api v3
PostPosted: Tue Feb 12, 2013 1:53 pm 
Offline

Joined: Thu Jan 17, 2013 5:05 am
Posts: 4
Hi friends ,

If you want to display different markers (custom Markers) in Google Maps api v3 , follow this

var customIcons = {
CA: {
icon: 'includes/images/1.png',
shadow: 'http://labs.google.com/ridefinder/images/mm_20_shadow.png'
},
MA: {
icon: 'includes/images/2.png',
shadow: 'http://labs.google.com/ridefinder/images/mm_20_shadow.png'
},
TX: {
icon: 'includes/images/brand.png',
shadow: 'http://labs.google.com/ridefinder/images/mm_20_shadow.png'
}
};

//while creating Markers obj pass this values
var marker = new google.maps.Marker({
position: latLng,
map: map,
icon: icon.icon,
shadow: icon.shadow
});

In above code CA ,MA,TX are catogeries variables (userdefined).
i hope it's useful

Regards,
bheema


Top
  
 
   [ 1 post ] 

1, 2, 3, 4, 5 ... 413
Recent topics  Replies   Views   Last post 
No new posts Benefits of PHP

by hirephpexpert » Fri Sep 07, 2012 4:41 am in CakePHP

5

1513

Tue May 07, 2013 6:06 am

amywatson View the latest post

No new posts CCavenue integration in php

by rajkumar » Fri Mar 04, 2011 3:34 am in Payment Gateways

2

8073

Tue Apr 30, 2013 5:48 am

sagarpatil0710 View the latest post

No new posts How to search for decimal values in post meta using WP_Query

by jimmybrion » Mon Apr 29, 2013 11:56 am in Others(phpBB, phpfox, etc..)

0

1220

Mon Apr 29, 2013 11:56 am

jimmybrion View the latest post

No new posts PHP

by jimmybrion » Mon Apr 29, 2013 8:38 am in PHP-Code Help

0

435

Mon Apr 29, 2013 8:38 am

jimmybrion View the latest post

No new posts Search Engine Optimisation

by chandra kanchana » Fri Jul 29, 2011 10:49 am in HTML

8

1640

Tue Apr 09, 2013 8:45 am

sunnyfun8507 View the latest post


Your Ad Here