Codice PHP:
<html>
<
head>
<
meta name="viewport" content="initial-scale=1.0, user-scalable=no"/>
<
meta http-equiv="content-type" content="text/html; charset=UTF-8"/>
<
title>Google Maps API v3Directions</title>
<
style type="text/css">
htmlbody margin:0padding:0width:100%; height:100%; }
body background:#FFFFFF; color:#000000; font-family:Arial, Helvetica, sans-serif; font-size:12px; line-height:150%; text-align:center;}
#map { width:100%; height:95%; }
input width:250px; }
</
style>
<
script type="text/javascript" src="http://maps.google.com/maps/api/js?sensor=false"></script>
<script type="text/javascript">
var directionDisplay;
var directionsService = new google.maps.DirectionsService();
var map;

function initialize() {
  
    calcRoute();
    directionsDisplay = new google.maps.DirectionsRenderer();
    var myOptions = { 
        zoom:7,
          mapTypeId: google.maps.MapTypeId.ROADMAP
    }
    
    map = new google.maps.Map(document.getElementById("map"), myOptions);
    
    directionsDisplay.setMap(map);
    
    document.getElementById("submit").onclick = function() {
        calcRoute();
    }
    
}
  
  function calcRoute() {
    var partenza = document.getElementById("partenza").value;
    var arrivo = document.getElementById("arrivo").value;
    var request = {
        origin:partenza, 
        destination:arrivo,
        travelMode: google.maps.DirectionsTravelMode.DRIVING
    };
    directionsService.route(request, function(response, status) {
      if (status == google.maps.DirectionsStatus.OK) {
        directionsDisplay.setDirections(response);
      }
    });
  }
window.onload = initialize;
</script>
</head>
<body>
<div>
[b]Partenza: [/b]
<input type="text" id="partenza" value="Via del Portonaccio - Roma">
[b]Arrivo: [/b]
<input type="text" id="arrivo" value="Via Zamboni - Bologna">
<input id="submit" type="button" value="trova percorso sulla mappa">
</div>
<div id="map"></div>
</body>
</html> 
Ho questo script...come faccio a visualizzare piu rotte!? sto smattando...