Hi, i'd like to draw line from point to point and I didn't get how to do it. I surf a lot on the web but i can't understand if is Gpolyline what I need to use and however I can't find the way to add this on my existent map. My map actually mark n points and the page is this:
http://www.travelblogs.it/member-diary.php?userID=51&&idblog=72 the code that I used is the following: function load() { if (GBrowserIsCompatible()) { var map = new GMap2(document.getElementById("map")); map.addControl(new GSmallMapControl()); map.addControl(new GMapTypeControl()); GDownloadUrl("maps-points.php?place=<? echo $place; ?>", function(data) { var xml = GXml.parse(data); var markers = xml.documentElement.getElementsByTagName ("marker"); for (var i = 0; i < markers.length; i++) { /*map.setCenter(new GLatLng(parseFloat(markers[i].getAttribute ("lat")), parseFloat(markers[i].getAttribute ("lng"))), 0);*/ map.setCenter(new GLatLng(41.90311,12.49576), 0); //ROMA var name = markers[i].getAttribute("name"); var address = markers[i].getAttribute("address"); var type = markers[i].getAttribute("type"); var point = new GLatLng(parseFloat(markers[i].getAttribute ("lat")), parseFloat(markers[i].getAttribute ("lng"))); var marker = createMarker(point, name, address, type); map.addOverlay(marker); } }); } } maps-points.php is a file that grab unformation to obtain points. How can I add trace lines? Are somewhere some examples that can help me? Thanks a lot. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Google Maps API" 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-API?hl=en -~----------~----~----~----~------~----~------~--~---
