Ok here's the story so far... I'm a beginner programmer messing around with the GPS functionality on my browser, Google Chrome. I'm looking at different tutorials for displaying the current location of the user on a website @ W3schools and I decide to see it it were possible to do the same with Open Street Map, instead of Google Maps. How can I utilize the OSM api to take the latitude and longitude returned from my browser? I've messed around with the default iframe offered by the OSM website, but to no avail. Any tips? asked 05 Jun '15, 13:17 roughlycuboid |
For a bit of background about creating a simple browser-based map that uses map tiles from OSM, have a read of this: https://switch2osm.org/using-tiles/getting-started-with-leaflet/ Leaflet (the Javascript library) supports a "locate" call - see http://leafletjs.com/reference.html . That allows you to centre the map display using the HTML Geolocation API. answered 05 Jun '15, 13:31 SomeoneElse ♦ |