Reputation: 113
i have a image names maker.png in project folder Image and I want to use it as google maker image how give proper path in Javascript .please help
Upvotes: 1
Views: 2008
Reputation: 199
for the Google Map V3 in javascript you can use it in this way
var marker = new google.maps.Marker({
position : new google.maps.LatLng(42.344333,-76.432333),
map : mapObject,
icon : 'images/icon.png',
title : 'My Marker'
});
This will help you!
Upvotes: 6
Reputation: 2526
Refer to the following URL, there are examples here
https://developers.google.com/maps/documentation/javascript/overlays#Icons
You can just say 'image/marker.png'
Upvotes: 2