wx.getLocation({
type: 'gcj02', //wgs84/gcj02
gltitude: true,
isHighAccuracy: true,
success: function (res) {
console.log('纬度' + res.latitude);
console.log('经度' + res.longitude);
wx.setStorageSync('latitude', res.latitude)
wx.setStorageSync('longitude', res.longitude)
},
})
微信小程序获取当前定位经纬度
最新推荐文章于 2024-07-25 18:18:28 发布