I am developing a hybrid application using IonicFramework. In my case Google Map is displaying on browser, but it is not displaying in Android device.
I have created Google Map key for browser. so it is working fine in browser. but it is not displaying in android.
So, My Question is -
Do i need to create separate google Map key for android as well?
If yes then, how do we integrate google Map code for both platform?
When using the Google maps Javascript API v3 a key is not even mandatory, so getting another one will not solve your problem.
Can you see what error you are getting? (if you got a device plugged in, go to "other tools" > "inspect devices" and check out the console over there.
Are you just getting a gray screen?
Related
I'm currently working on android project using google maps API. But i can't seem to access my google console API.
Everytime i used the link provided by the android studio.it always ended as a blank white page.
Does anyone know how to solve it?
Click here to go to console page. It will ask you to sign in first in case you are not signed in. After that you have to create a new project there and have to specify which API you are going to use.
Is using google maps for android SDK in China working?
I've been trying by VPN and it's not working.
Is there some SDK setting I'm missing?
Like the javascript api allows change the url to
http://maps.google.cn/
If not, can anyone give me some suggestion?
I've been trying the Skobbler OSM Maps, the speed of randomly loading when loading the world wide map area is so slow.
Does it works by using the webview (Google map javascript API) ?
Our app need to show the global countries map, including China area.
Many Thanks
you can change the google maps to GaoDe (amap).
First because Google maps need the googles services, which are not available on Chinese phones.
Then because if there is a way with JavaScript to get to the Chinese google map ( see the following link: developers.google.com/maps/faq?hl=en#china_ws_access ), for android with java it is still not reliable.
I am currently developing app using Cordova / Phonegap. In my app, I want to check if Google Maps app is available. I am using this plugin for android and it works. It goes to the MAPS app since it is available. When I disabled the Google Maps app, it went to the error callback which is perfect. In the error callback, I tried to open the Play Store app, which also works. What I am trying to do is, when the Play Store app is opened, I want to the Play Store to open the MAPS page for me. Is it achievable? Also I want to know if there is a similar plugin like this for iOS. Or should I just open the app using an InAppBrowser? I am new to Web Technologies so I need some advice on this.
Thanks! :)
For android:
Install inAppBrowser. make a system call like
window.open("market://details?id=com.google.android.apps.maps","_system");
This is found here
window.open('itms-apps://itunes.apple.com/us/app/domainsicle-domain-name-search/id511364723?ls=1&mt=8','_system');
set the map id. I don't know the market ID for map app for ios.
iOS example found here
I had working code showing my location on a nice little google map. with out changing any map code suddenly the map is completely blank (a grey grey square) thats it..
using google map api for android v2. all set up with an api key and everything.. it was working!
This can happen for a few reasons. Did you sign this version of the application with a different certificate? Are you sure your device has an internet connection? You can also check the logs as Google Maps usually spams a bunch of information about why it is unable to connect. I run into this issue sometimes when my phone is running internet through a proxy, you might want to check that as well.
i have made an android application and in it , there is one scenario when the user clicks on an address and that address shows up on google maps.
Now when i tested the application on the emulator, the google maps did load properly, but now that i am trying the same on my htc desire z, the maps is not loading.
Although the maps application which came built-in in my phone is loading google maps correctly.
what could be the problem? why is my application not able to load the map view?
thank you in advance.
EDIT: i have obtained a google map api key and have included it in the mapview that i am using.i have added overlays and etc. It is all showing fine on the emulator , but on my device it is not showing any maps. The overlays are visible.
There is a difference between a debug maps API key and a release maps API key. With the first it will only run on the emulator.
Unless you have visited the Google site twice (once to get a key which matches the debug keystore and once to get a key which matches your release keystore) then you haven't got a release key and your app won't run on real device.
Our Android developers were also facing this problem. We solved the problem like this:
We generated API keys from each machine and added the Key to their respective main.xml file. So each developer had a separate api key.
We started the emulator from the command line using the android "emulator" command which is located in the tools directory and started with the proxy option instead of starting it from eclipse, eg :
E:>emulator -avd New_Device -http-proxy http://202.0.0.203:808
Most probably, you didn't register your application into the system. This is the link.
http://code.google.com/android/add-ons/google-apis/maps-api-signup.html
If this is not the case, please provide the error details from Logcat.
You need to get an API key from Google.
Here is a good article that explain how to obtain API key.