地理编码 - 地图不以用户位置为中心

发布于 2024-12-26 21:42:58 字数 370 浏览 2 评论 0 原文

我遇到一个问题,我的地图从选项卡中滑出,目前它应该以用户位置为中心,请参阅下面的 jsfiddle:

http://jsfiddle.net/uADHv/2/

据我了解,该行:

center: coords,

应该将地图以用户当前位置为中心,但显示一个接近的随机位置实际位置但很远距离足够远,以至于在地图上看不到。

任何查看地图中心位置的 jsfiddle 链接帖子的人都可以,我很好奇它是否会在靠近他们所在位置的某个地方,或者是否会在每个人的同一个地方中心。

谢谢

I'm having a problem where my map slides out from a tab and at the moment it is supposed to be centering on the users location, see jsfiddle below:

http://jsfiddle.net/uADHv/2/

From what I understand the line:

center: coords,

should be centering the map on the users current location but is showing a random location which is close to the actual location but far enough away so that it isn't visible on the map.

Also could anyone who looks at the jsfiddle link post where the map is centering on, i'm curious to whether it will be somewhere close to where they are or if it will center in the same place for everyone.

Thanks

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。
列表为空,暂无数据
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文