I have not brought a complete code example, because I have a perfectly
running a standard version of geocoding by INPUT and it uses the same code.
But if it helps, here is complete:
var map;
var timestamp = new Date().getTime();
var readyLayer = new
google.maps.KmlLayer('actionsmap/maps/ready.kml?'+timestamp);
var dirtyLayer = new
google.maps.KmlLayer('actionsmap/maps/dirty.kml?'+timestamp);
function initialize() {
var myLatlng = new google.maps.LatLng(110.186055, 65.45309);
var myOptions = {
zoom: 9,
center: myLatlng,
mapTypeId: google.maps.MapTypeId.ROADMAP,
scrollwheel: true,
scaleControl: true
}
map = new google.maps.Map(document.getElementById("map-container"),
myOptions);
var openStreet = new google.maps.ImageMapType({
getTileUrl: function(ll, z) {
var X = ll.x % (1 << z); // wrap
return "http://tile.openstreetmap.org/" + z + "/" + X + "/" + ll.y + ".png";
},
tileSize: new google.maps.Size(256, 256),
isPng: true,
maxZoom: 18,
name: "OSMap",
alt: "Слой с OpenStreetMap"
});
map.mapTypes.set('osm', openStreet);
map.setMapTypeId('osm');
readyLayer.setMap(map);
map.setOptions({
mapTypeControlOptions: {
mapTypeIds: [
'osm',
google.maps.MapTypeId.ROADMAP,
google.maps.MapTypeId.TERRAIN,
google.maps.MapTypeId.SATELLITE,
google.maps.MapTypeId.HYBRID
],
style: google.maps.MapTypeControlStyle.DROPDOWN_MENU
}
});
}
and function above. All that I need to navigate through the markers from
KML.
Variant with LatLng difficult, but if the first does not work, tell me how
to use it?
--
You received this message because you are subscribed to the Google Groups
"Google Maps JavaScript API v3" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/google-maps-js-api-v3?hl=en.