GetcurrentPosition doesn't work once deployed

前端 未结 1 1459
面向向阳花
面向向阳花 2020-12-22 12:50

I\'m trying to initialize a Map centered and with a marker on current user\'s position. In local everything fine, but when i deploy the html page to Google Appengine, it sho

相关标签:
1条回答
  • 2020-12-22 13:12

    Chrome no longer supports geolocation on insecure origins. You must use HTTPS:// if you want to use geolocation.

    See the message in the console:

    getCurrentPosition() and watchPosition() are deprecated on insecure origins. To use this feature, you should consider switching your application to a secure origin, such as HTTPS. See https://sites.google.com/a/chromium.org/dev/Home/chromium-security/deprecating-powerful-features-on-insecure-origins for more details.`

    0 讨论(0)
提交回复
热议问题