Search code examples
jquery-uigoogle-mapsjquery-pluginsoverlays

overlayMapTypes using jquery-ui-map plugin


I'm showing some map tiles with google maps api v3 and jquery-ui-map (http://code.google.com/p/jquery-ui-map/)

And then I have this instruction:

map.overlayMapTypes.insertAt(0, trafficMapType);

And I don't know how to translate this using the jquery-ui-,ap plugin.

I have tried things like:

$('#map_canvas').gmap('overlayMapTypes','insertAt',google.maps.overlayMapTypes.insertAt(0, trafficMapType));

But it doesn't work.

Someone please help me. Thank you


Solution

  • This is how you would do it.

    $('#map_canvas').gmap('get', 'map').overlayMapTypes.insertAt(0, trafficMapType);