麻烦与谷歌地图API密钥 [英] Trouble with google maps api key

查看:138
本文介绍了麻烦与谷歌地图API密钥的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我导出了一个android包文件,并通过eclipse创建了一个新的密钥库。该应用使用谷歌地图。应用程序在调试模式下正常工作,但在运行apk后,应用程序不再显示地图,只显示空白图块。我有一个谷歌地图API密钥,但它不适用于发布版本。我假设我需要一个非调试映射API释放的关键。

如何访问我生成的私钥以获取地图API密钥?从我读过的私人密钥是需要获得谷歌地图API密钥。我可以在保存的文件位置看到生成的密钥文件,但无法打开它。



希望这是有道理的。提前致谢!

解决方案

在开发过程中使用相同的keystore签署生产.apk以注册Maps API密钥,您正在为您的Maps API密钥使用调试密钥库。


I exported an android package file and created a new keystore through eclipse. The app uses google maps. App works fine in debug mode but after running the apk the app no longer displays the map, only blank tiles. I had a google maps api key but it's not working for the release version. I'm assuming that I need a non-debug maps api key for the release.

How can I access the private key I generated to obtain a maps api key? From what I've read the private key is needed to get a google maps api key. I can see the generated file for the key at the file location it was saved but cannot open it.

Hope this makes sense. Thanks in advance!

解决方案

Use the same keystore you sign your production .apk to register for the Maps API key, since in development, you are using the Debug keystore for your Maps API key.

这篇关于麻烦与谷歌地图API密钥的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆