Closed sunstarwar closed 2 years ago
As mentioned in the README.md from this plugin project, the https certificate from the https://router.project-osrm.org URL expired.
You can't really avoid to use your own server for OSRM (see below screenshot from the mentioned README.md
). Imagining your server could be hosted without a certificate, (so without https only http), you would be able to call OSRM demo url without http but you would be stuck by another problem: you absolutely need https for using geolocation e.g https://developer.mozilla.org/en-US/docs/Web/API/Geolocation_API
As of today, the OSRM's demo server seems to be back again and is presenting a valid certificate for HTTPS verified by Let's Encrypt:
Probing the routing service via HTTP GET with an URL copied from the API documentation seems to produce a valid response.
But nevertheless currently the demo page for leaflet-routing-machine still shows an error message:
Hello, It is said that we should be using our own server. But if we are not able to use a valid certificate, how should we proceed ??? Because using the demo server, we will always be limited to a certain number of requests per second...
But if we are not able to use a valid certificate, how should we proceed ???
You have a few options.
Because using the demo server, we will always be limited to a certain number of requests per second...
The demo server is generally feasible if you want to prototype some application. It's not suitable for production use since it would probably drastically increase server load (and cost) for the OpenStreetMap folks and as such throttle all the other people wanting to use the demo server.
That being said, the demo server is working fine now as can be seen in the docs. They use https://routing.openstreetmap.de/routed-car/route/v1 for routing now by default
Closing as this seems to be resolved. If the issue persists, feel free to open another one or ask me to reopen this one
Hi friends,
i am working in a leaflet routing map, when i was working in a local machine it doesn't say error but when i move the code to server throws an error like "leaflet-routing-machine.js:88 Mixed Content: The page at 'https://moesctest.artha.com/Employee/Students_OnRoute_OSM.aspx' was loaded over HTTPS, but requested an insecure XMLHttpRequest endpoint 'http://router.project-osrm.org/route/v1/driving/-74.1170343,40.4456482;-74.1195227,40.4440501;-74.1189951,40.4431026;-74.1234684,40.4424305;-74.126634,40.4413222;-74.1290197,40.4491485;-74.1305336,40.4500597;-74.1352131,40.4517255;-74.1372316,40.4491365;-74.1374725,40.4490829;-74.129298,40.4371859?overview=false&alternatives=true&steps=true&hints=;;;;;;;;;;'. This request has been blocked; the content must be served over HTTPS."
I dont know much knowledge in leaflet routing machine, so i need help to make this work in server any help would be appreciated..
thanks in advance...