10/7/2019 Google Maps Api Key
The Scrivito Example App comes with a Google Maps widget you can use on any page. The location the widget should display as well as a couple of display options can be set via the widget properties. However, after closing the properties dialog, the map might not be displayed if you haven’t provided the app with a Google Maps API key.
![]() ![]()
In the older version of the API, I'd have to insert the javascript into the page using something like this for just basic functionality to work:GoogleMapsAPIKeyWhere I had to configure the API key for each individual site. Looking at the documentation, it says to get a basic map working I just need this:true/falseWhere does the API key fit in? Do I need to worry about it if I just plan on using a basic map and marker and none of the more advanced functions?I'm also testing on localhost, but the FAQ says I still need to register a key for it, which I haven't done and it still works.
Whilst it is true that V3 of the Google Maps API does not require an API key, it is there for a reason. Google recently introduced the following:Web sites and applications using each of the Maps API may at no costgenerate:. up to 25,000 map loads per day for each API. up to 2,500 map loads per day that have been modified using the Styled Maps featureIn order to monitor usage an API key is necessary, as:All Maps API applications should load the Maps API using an API key.Using an API key enables you to monitor your application's Maps APIusage, and ensures that Google can contact you about your applicationif necessary.
If your application's Maps API usage by exceeds theUsage Limits, you must load the Maps API using an API key in order topurchase additional quota.So whilst you don't need to have an API key it is useful if you want to monitor your usage and also required if you buy additional usage quota. You can't use google maps in Android app unless you create a google map key. You need to use keytool to generate MD5 and use that to generate google map key on google map website. Keytool should be located on your computer where you have sdk installed. I have generated developer google map key, and I have noticed that key is only good for developing Android app on that particular computer.
If you are going to develop Android app on an another computer then you need to generate another google map key for that computer. If you don't see a google map on your Android app but rather you see a grid, this could mean that your google map key is invalid.
Comments are closed.
|
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |