OpenStreetMap logo OpenStreetMap

Post When Comment
Show track on OSM map

to Joost: Indeed, since OSM changed its export trace format to bz2 (1st Qtr 2013), and as I’ve not succeeded to uncode the OSM bz2 file with php, I switched the source of the supported traces from OSM to Garmin Connect. The id parameter which is now supported by this service is the activity number in Garmin connect. If someone can point me to how to uncode bz2 file in php, I would be happy to support OSM trace file again.

Show track on OSM map

a bit but with a bit more. differences are:
1. track shown fully on screen and centered, with continuous semi transparent line;
2. callable directly by URL so that you can embed it in a page or type in the URL bar of the browser. The osm.org link that you suggest above requires keying in the id on screen and I do not see how to embedded it.
Got most inspiration for the js code from osm.wiki/User:MHohmann#Application:_GPX_layers_with_popups_in_OpenLayers. But there is as well some PHP needed to access the track on OSM, get its bounds and center and pass it the js script and openlayer.