Pregunta

I was able to get the static path on the map like this using the code but unable to show the starting and ending points

http://maps.googleapis.com/maps/api/staticmap?sensor=false&size=600x600&zoom=12&path=color:0x0000ff|weight:5|40.737102,-73.990318|40.749825,-73.987963|40.752946,-73.987384|40.755823,-73.986397

Here I was unable to show the markers for the starting point and at the ending point.

How to put the points on starting and ending points

Unable to place the points

Please help me to find the solution

¿Fue útil?

Solución

You need to add a markers URL parameter. Like this:

http://maps.googleapis.com/maps/api/staticmap?sensor=false&markers=size:mid%7C40.737102,-73.990318|40.755823,-73.986397&size=600x600&zoom=12&path=color:0x0000ff|weight:5|40.737102,-73.990318|40.749825,-73.987963|40.752946,-73.987384|40.755823,-73.986397
Licenciado bajo: CC-BY-SA con atribución
No afiliado a StackOverflow
scroll top