Script does not show map

Asked

Viewed 290 times

1

I’m wearing this script:

https://github.com/ChadKillingsworth/geolocation-marker/releases/tag/v2.0.4

The error in the console is this:

"Google Maps API error: Missingkeymaperror Developers.google/maps/Documentation/javascript/error-messages#Missing-key-map-error"js:34:391

"Google Maps API Warning: Noapikeys Developers.google/maps/Documentation/javascript/error-messages#no-api-Keys"

Error image:

img do erro

  • Mark, take a look in that reply of mine on another question, and click Run. Basically you need to create a key for your project on Google Apis console

  • Already created the key api, the code has no place to put the key, have any key api defined to create in this case? -

2 answers

1

  • already created the code itself does not even ask for information for key api, grateful.

1

After get a key to the Google Maps Geolocation API

Check that all Google Maps Apis are enabled on Google Apis console inserir a descrição da imagem aqui

I also recommend reading this communiqué in English in which the following information is described:

"Chrome no longer supports obtaining user location using the HTML5 Geolocation API from pages delivered by connections not secure. This means that the page making the API call Geolocation should be served from a safe context , as HTTPS" .

  • http://get-play.org/test/index.html used the code for the current location of the person but from the same script error I used to post this topic, this is the script you gave me -> http://www.linhadecodigo.com.br/artigo/3653/usando-geolocation-com-Html5.aspx have any idea what may be happening have key api but the error persists

  • @Marcosdaviddossantossoares gave an edited answer I think now it is more complete.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.