I am getting my Localisation on Leaflet map using the extension. Leaflet.Locate
When I am on my local server it works fine like shown bellow:
But when I am on a remote server I get this error. How to solve this.
I am getting my Localisation on Leaflet map using the extension. Leaflet.Locate
When I am on my local server it works fine like shown bellow:
But when I am on a remote server I get this error. How to solve this.
Most browsers now disable geolocation unless you are connected to a secure server ('https' vs 'http'). This is a sensible precaution for personal protection among other things.
To over come this you need to connect to a secure server or, if you are developing the server yourself, you need to implement https. To do that you will need to get signed certificates to authenticate your server. Have a look at LetsEncrypt. There are paid-for solutions available.