How long are Google Static Map custom markers cached for?
When setting a custom marker and then changing it (eg, using the same file name but a different image) it seems to cache the first file used. This is awkward when tweaking a design.
Once you have the area you'd like to cache in view, type “okay maps” into the search box. Google will take a moment to “pre-load” the area and then save the copy to your device's offline cache. Once it's cached you can use the map at any time, even in Airplane mode.
2048 characters in URL is just under 100 GeoCode values. So, again no more than 100 markers.
The maximum is 15. Note that this limit applies only to markers specified as a human-readable address that requires geocoding. It does not apply to markers specified with latitude/longitude coordinates. Too many geocoded polyline vertices requested (max is 15).
The Maps Static API uses a pay-as-you-go pricing model. Requests for the Maps Static API are billed under the SKU for Static Maps. Along with the overall Google Terms of Use, there are usage limits specific to the Maps Static API. Manage your costs and usage with tools available in the Google Cloud Console.
As far as I know there is no policy for this (so it may change without notice) - right now they seem to expire in 1 day.
Requesting http://chart.apis.google.com/chart?chst=d_map_pin_icon&chld=cafe|996600 returned the following headers
Date Tue, 16 Nov 2010 00:35:41 GMT
Expires Wed, 17 Nov 2010 00:35:41 GMT
Cache-Control public, max-age=86400
You can pass extra parameters to the static maps API if you want to, Google will just ignore them and you can use it for cachebreaking. We did this all the time for testing in a place I used to work.
Usually we tagged the time onto the url in the request, and it'd prevent it from being cached:
http://chart.apis.google.com/chart?chst=d_map_pin_icon&chld=cafe|996600&time=1290371937
Or set your web browser to stop caching images while you're testing.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With