0
votes

I am trying to create a google map using the static google map API. I want walking and driving static map.

Bellow is the path i am using : http://maps.google.com/maps/api/staticmap?maptype=roadmap&zoom=14&size=400x250&markers=color:green|label:A|30.7261629,76.7596221&markers=color:red|label:B|30.7226447,76.7681678&path=color:0xff0000ff|weight:3|30.7261629,76.7596221|30.7226447,76.7681678&sensor=false

1
What you have tried, can you provide the code you tried?Falaque
I am trying to show the map by just using the path : maps.google.com/maps/api/…user2940248
Can you modify this path in such a way that it can generate a map with driving route from A to B. ?user2940248

1 Answers

1
votes

Static map api support only marker not direction.

If you want to use direction with Static map, you need to use direction api.

How to do: how to create a static api map with directions

Basically what the up-voted answer is saying:

1. Use direction api to get encoded path.
2. In static map use this encoded path.