google-mapsdirections

How do i not show alternative routes through google map


I have tried like this but still i am not getting.. https://www.google.com/maps/dir/?api=1&origin=28.7041,77.1025&destination=25.5941,85.1376&travelmode=driving&alternatives-parameter=false

I guess, I am missing some parameters


Solution

  • Control of alternate routes is only (currently) available in the Google Maps Javascript API v3 DirectionsService and in the Directions Web Service.