getLocation,换了位置后经纬度坐标为什么不变?

发布于 8 年前作者 xiuying939642 次浏览最后编辑 8 年前来自 issues

wx.getLocation在单位获取经纬度后,回家测试经纬度坐标不变化。海拔信息也不能显示,求指教

我使用的调用如下:

var that = this

wx.getLocation({

type: ‘gcj02’,

altitude: true,

isHighAccuracy: true,

success: function (res) {

console.log(res)

that.setData({

longitude: res.longitude,

latitude: res.latitude,

altitude: res.altitude,

})

},

})

开发环境版本

4 回复
hujie
hujie1 楼6 年前

也许是缓存,还没有刷新。

dengyang
dengyang2 楼6 年前

麻烦提供能复现问题的代码片段(https://developers.weixin.qq.com/miniprogram/dev/devtools/minicode.html

另外,请扫描下图贴一下截图

gang28
gang283 楼6 年前

你是每次更换地址打开小程序都需要更换定位是不?

juan15
juan154 楼6 年前

你确定你的电脑支持GPS定位?