google-maps-api-3

Google map API v3 event click raise when clickingMarkerClusterer?

I have a Google Map API v3 map object on a page that uses MarkerClusterer. I have a function that need to run when we click on the map to it is registered as: google.maps.event.addListener(map, 'click', function (event) { CallMe(event.latLng); }); So my problem is as follows: When I click on a cluster of MarkerClusterer instead of...

Google Maps API v3 - infoWindows all have same content

Hello, I've been having problems with the infoWindows and Google Maps API v3. Initially, I've ran into the problem that everyone else has of closing infoWindows when opening a new one. I thought to have solved the problem by defining "infowindow" beforehand. Now they close when I click on a new marker, but the content is the same. How ...

Google Maps V3: Infowindows not resizing to fit information

Problem I have a API V3 map, with a content window for each marker. The content of the infowindow stretches across multiple lines, but the infowindow does not resize to fit it all, causing an iframe-like scroll to appear. I have looked at the setContent() method in the API which according to some posts on the API V3 mailing list should...

Why does Internet Explorer break "pegman" display in Google Maps API v3?

On my site here, the SteetView control, aka "Pegman", works great under Firefox. Under IE (7 in this case, but tested on 8 as well - same result) it breaks the display of the pegman control. Here's my map code: var directionsDisplay; var directionsService = new google.maps.DirectionsService(); var map; directionsDisplay = new google.m...

What's the most efficient way to create routes on google maps from gps files?

I want to display my bicycle routes on Google maps. All the coordinates are recorded by my GPS and stored in .gpx file format. I'd like to know what's the best approach/file formats/storage/loading the coordinates on Google Maps. This is a good example but it doesn't seem to be working. ...

How to make cross-domain AJAX calls to Google Maps API?

I'm trying to make a jQuery $.getJSON call to the Google Maps Geocoding webservice, but this doesn't work because of cross-domain security issues. I haven't been able to figure it out online, but I've read a bit about Google Javascript API or JSONP, but so far no clear answer... Could anyone enlight me? Thanks! ...

Google Map API V3 geocoder not showing the correct place

I am upgrading my codes from Google Map API V2 to V3. In V2, I used GlocalSearch to get the latitude and longitude for the given address. In V3, I saw google.maps.Geocoder() and try to get the similar detail. However, the lat & long given by the V3 function is not accurate. Pls see the following screenshot here: My codes for V3 are...

GInfoWindowTab function equivalent in Google Map API v3

Is there any function in Google Map API Version to show the multiple tab info windows like the following example? Example This example is done by using Google Map API Version 2. I am wondering the equivalent function in Google Map API v3. I can only find the google.maps.InfoWindow which is the popup window without Tab. Thanks. ...

Google Maps V3: Only show markers in viewport - Clear markers issue

Hello, I like to create a map with Google Maps that can handle large amounts of markers (over 10.000). To not slow down the map I've created a XML-file that only outputs the markers that are inside the current viewport. First, I use initialize() to setup the map options: function initialize() { var myLatlng = new google.maps.L...

Google Map API v3 ~ Simply Close an infowindow?

Trying to simply close an infowindow? I already have an array of markers, so something like this would be good. Thanks MyMarkers[i].infowindow.close(); ...

Google Maps API v3 - How to clear overlays ?

Hello, In Google Maps API v2, I was using map.clearOverlays() to remove the marker and draw them again. How can I do that using Google Maps API v3 ? Thanks ...

Google maps api - polygon mouseover

I am using google maps API v3 and have created several polygons on the map. I want the functionality that when the user hovers over a given area (polygon) the individual polygon changes color. Is there any way to do this? (Later I'd like to be able to register mouse events on the given area as well). thanks. ...

Javascript callback and google maps api question

I am using google maps api v3 and have an array of arrays object: MVCArray.<MVCArray.<LatLng>> I want to iterate over this. I see that MVCArray has a method forEach which uses a call back, but I have no idea how to use this (I haven't done much js). The api defines this method as follows: forEach(callback:function(*, number))) C...

Highlight polygon and tint rest of map using Google Maps

Hi, I'd like to display a highlighted polygon using Google Maps. The idea is that the polygon in question would be displayed normally and the rest of the map should be darkened a little bit. Here's an example image what I would like to accomplish with a polygon from Austria: Unfortunately, I'm a complete rookie when it comes to Goo...

Closing any open info windows in google maps api v3

As the title states, on a given event (for me this happens to be upon opening a new google.maps.InfoWindow I want to be able to close any other currently open info windows. Right now, I can open many at a time..but I want only 1 open at a time. I am creating the info windows dynamically (i.e. I don't know ahead of time how many will be...

Google maps api Directions User defined Steps

Hi All, I have a google map service with the stores mapped on it. I also have directions service (then you define two addresses or more and it shows you a way on this map, see google map api directions). So I waте to show the nearest stores to this way. Of course it could be the store located in the next streat of my way, so it also sho...

gmaps Address Component Types get country name

hi .. iam trying to get the country name using the Address Component Types available from gmaps V3. i dont know how i can get it the right way.. http://code.google.com/apis/maps/documentation/javascript/services.html#GeocodingAddressTypes iam trying to alert the country name liks here : alert(results[1].address_component[country]); ...

Google Maps v3: Enforcing min. zoom level when using fitBounds

I'm drawing a series of markers on a map (using v3 of the maps api). In v2, I had the following code: bounds = new GLatLngBounds(); ... loop thru and put markers on map ... bounds.extend(point); ... end looping map.setCenter(bounds.getCenter()); var level = map.getBoundsZoomLevel(bounds); if ( level == 1 ) level = ...

Directions renderer overdrives kml layer

Hi, I have a map where DirectionsRenderer() finds route from one point to another. This works fine. In addition I fetch GeoRSS from Flickr and it shows the geotagged images in the map also correctly. BUT the flickr markers are not active. How can I get those markers active? To open the flickr image in InfoWindow. It works correctly if...

GoogleMaps API v3 - Need help with two "click" event scenarios. Need similar functionality to v2 API...

In version 2 of the API the map click event returned an Overlay, LatLng, Overlaylatlng. I used this to create a generic map event that would either retrieve the coordinates of the Map click event, or return the coordinates of a Marker or other type of Overlay. Now that API v3 doesn't return the Overlay or Overlaylatlng during the map c...