google-maps-markers

Google map API marker with letter on map

折月煮酒 提交于 2019-11-30 08:53:40
问题 Is there a way to access the colored markers with a letter from google? I can only use the red ones with letters like But I need green markers with a letter like I get it from the directions API from google. Like this one here Is there a way to access to the colored markers with letter? Or do I have to add the markers to my image folder? 回答1: You must use : http://chart.apis.google.com/chart?chst=d_map_pin_letter&chld=D|00FF00|000000 chld parameter is the letter you want to appear in your

Pulse ring animation around a Google Maps marker iOS

断了今生、忘了曾经 提交于 2019-11-30 07:55:41
I want to add a pulse ring animation around a marker as a current user location in iOS google maps (like Uber). I tried with adding CABasicAnimation to marker layer by addAnimation . It is not working. Also I tried animate the scale of the marker but the scale change did not happen. Can anybody help me with this thing? Antony Raphel somehow it is working now. I created a custom view and set that view into GMSMarker iconView . After that added animation into view layer. UIView *view = [[UIView alloc] initWithFrame:CGRectMake(200, 200, 100, 100)]; view.backgroundColor = [UIColor redColor]; view

Add numbering label to google map marker

只愿长相守 提交于 2019-11-30 07:45:02
May I know how to add numbering label to google map marker using google map api? Just add label, not trying to change the icon. Thank you. If you don't want to use custom icons for each marker then I suggest looking into creating a label class with the OverlayView and then binding the position to the marker. Or you could look at using something like: http://github.com/nmccready/google-maps-utility-library-v3-infobox Alex Angelico I think a better solution is to use a infoWindow. Something like this: $(document).ready(function () { var golfoMexico = new google.maps.LatLng(20.61536,-87.078975);

Marker click event on react native maps not working in react ios

人走茶凉 提交于 2019-11-30 07:23:12
I have tried by calling onPress method in MapView.Marker Tab, but its not working. This method for tracking marker click: markerClick(){ console.log("Marker was clicked"); } In render method, Map components are declared to display map and markers on map. In onPress method I have called my custom method markerClicked(). Still I am not getting the result. render() { return ( <View style={styles.container}> <MapView style={styles.map} initialRegion={{ latitude: 37.78825, longitude: -122.4324, latitudeDelta: 0.0, longitudeDelta: 0.0, }} > {this.state.markers.map(marker => ( <MapView.Marker

How to hide and show MarkerClusterer in google maps

梦想与她 提交于 2019-11-30 07:18:04
i'm trying to hide/show markerClusterer when user clicks some buttons: Here is what i'm trying to do: map = new google.maps.Map(document.getElementById("mappa"),mapOptions); var marker_tmp = []; var markers_tmp = []; $.each(json,function(index,value){ var latLng = new google.maps.LatLng(value.lat,value.lng); var marker = new google.maps.Marker({'position': latLng}); if((value.candidato in markers_tmp)==false){ markers_tmp[value.name]=[]; } markers_tmp[value.name].push(marker); }); for(var name in markers_tmp){ markers[name]= new MarkerClusterer(map,markers_tmp[name]); } I create multiple

google maps v3 marker mouseover tooltip

本小妞迷上赌 提交于 2019-11-30 06:33:51
I want to put a tooltip made myself with divs when the mouse is over a marker, but I don't know how to get the screen position to put the div on the correct position, here is my code: google.maps.event.addListener(marker, "mouseover", function() { divover.css("left", marker.get("left")); divover.css("top", marker.get("top")); divover.css("display", "block"); }); google.maps.event.addListener(marker, "mouseout", function() { divover.css("display", "none"); }); Obviously the get method fails. Any Idea? This is a tricky one. In v2 of the API, you can do: map.fromLatLngToContainerPixel(marker

Google maps infowindow showing on wrong marker

情到浓时终转凉″ 提交于 2019-11-30 06:28:26
I have a piece of javascript code where I create markers and attach InfoWindows to them, like this: for (var i = 0; i < 8; i++) { var marker = new google.maps.Marker({ map: map, position: new google.maps.LatLng(lat[i], lng[i]), icon: '/static/images/iconsets/gmap/iconb' + (i+1) + '.png', }); var infowindow = new google.maps.InfoWindow({ content: 'test string' }); google.maps.event.addListener(marker, 'click', function() { infowindow.open(map,marker); }); } But when I click one of the markers, the infowindow always shows only on one marker. What am I doing wrong? There's a very simple solution

Starting Google Maps App with provided location and marker

北战南征 提交于 2019-11-30 06:21:12
From my app I would like to start the Google Maps App with a provided location and a marker. The marker should indicate, that there is something on that given location. For now, I have the following code, which starts with an Intent the Google Maps App with the provided location (51.49234, 7.43045). startActivity( new Intent( android.content.Intent.ACTION_VIEW, Uri.parse("geo:51.49234,7.43045"))); When the Google Maps App starts, it looks like the following: No marker is shown. I would like, that the Google Maps App would show a marker on that position, which is given through the Intent. Is

Use a URL to link to a Google map with a marker on it

女生的网名这么多〃 提交于 2019-11-30 06:14:29
问题 I want to link to google maps at a particular location with a marker on a particular point. It's easy to link to a location: http://maps.google.com/?ll=XX.XXXX,XX.XXXX But how do I drop a marker at that point too? preferably with a bit of my own text but that's just a bonus. 2017 - Google has released documentation on this see new accepted answer: https://stackoverflow.com/a/44477650/359135 回答1: In May 2017 Google launched the official Google Maps URLs documentation. The Google Maps URLs

Removing a Marker in Google Maps API v3

﹥>﹥吖頭↗ 提交于 2019-11-30 06:02:48
I'm trying to remove a marker that was initialized like this: marker = new google.maps.Marker({ position: latLng, map: map, draggable: true, animation: google.maps.Animation.DROP, title: 'Marker 1', icon: redPin }); google.maps.event.addListener(marker, "click", function() { showMarkerDialog(marker.position, "marker"); }); google.maps.event.addListener(marker, "dblclick", function() { // Add a alert: Are you sure you want to remove this marker? map.removeOverlay(marker); }); Everything works perfectly except that when I double click it to remove what I get on the Error Console is this: