【发布时间】:2013-12-14 01:26:07
【问题描述】:
<script type="text/javascript">
$("#test").gmap3({
getroute:{
options:{
origin:"Trenggalek, Indonesia",
waypoints: [{location: "Blitar, Indonesia", stopover: false},{location: "Malang, Indonesia", stopover: false}],
destination:"Surabaya, Indonesia",
travelMode: google.maps.DirectionsTravelMode.DRIVING
},
callback: function(results){
if (!results) return;
$(this).gmap3({
map:{
options:{
zoom: 13,
center: [-33.879, 151.235]
}
},
directionsrenderer:{
options:{
directions:results
}
}
});
}
}
});
</script>
但是当我用纬度和经度改变位置时,就会发生错误
waypoints: [{location: "Blitar, Indonesia", stopover: false},{location: [-7.988518,112.619262], stopover: false}],
如何使用经纬度改变位置?
【问题讨论】:
标签: javascript jquery google-maps map