I tried to display road network info in the respective infoWindow generated by Direction
Render marker.E.g Marker A when click the infoWindow contain all details from A to B.
Besides, an array of waypoints are shown between the source and destination. The
informations are not shown on InfoWindow popup. Here is part of the code. Any hint might
help thanks.
directionsService.route(request, function (response, status) {
if (status == google.maps.DirectionsStatus.OK) {
var roadInfo = document.getElementById("directionsPanel");
roadInfo.innerHTML="<b>"+response.routes[0].roadInfo+"</b>";
directionDisplay.setDirections(response);
var myRoute = response.routes[0].legs[0];
google.maps.event.addListener(request, 'click', function() {
// Open an info window when the marker is clicked on,
// containing the text of the step.
displayStep.setContent(request,myRoute.steps[i].instructions);
});