gpt4 book ai didi

ssl - 通过 SSL 使用 Google map API

转载 作者:太空宇宙 更新时间:2023-11-03 12:58:25 30 4
gpt4 key购买 nike

所以,我最近才知道 google maps API 现在可以在 SSL ( here ) 中使用。

我的问题是,如何改造我的 http google maps api 脚本以使用它?

所以我的 http Google maps API 脚本调用如下所示:

http://maps.google.com/maps?file=api&v=3&sensor=false&key=########

他们建议通过 this使用 SSL 的链接应该是这样的:

https://maps-api-ssl.google.com/maps/api/js?v=3&sensor=false

我试过将其 retrofit 成我的旧 URL 格式,如下所示:

https://maps-api-ssl.google.com/maps/api/js?v=3&sensor=false&key=########

但这不再显示 map 。

有人对 URL 应该是什么有什么建议吗?

谢谢

最佳答案

试试这一行:
https://maps.google.com/maps/api/js?v=3.5&sensor=true
谷歌 btw 建议您明确输入您将要使用的 api 版本。只需输入 v=3 将始终返回最新版本,目前为 3.5。我相信当前的稳定版本是 3.3。
正如 Trott 在他的回答中所写,不再需要 api key 。

关于ssl - 通过 SSL 使用 Google map API,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/6088303/

30 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com