waymarkedtrails / waymarkedtrails-website

Website code for https://waymarkedtrails.org
GNU General Public License v3.0
11 stars 3 forks source link

Possibility to create static link to map which is focused on route #4

Closed vanjakom closed 2 years ago

vanjakom commented 2 years ago

Is it possible to create static link ( to be used from other website which will point to hiking.waymarkedtrails.org ) which would show route details and center map on route without calculation of map parameter?

Background: I'm part of trails working group inside Mountaineering association of Serbia. In past we added all trails that are registered with Association to OSM and now we would like to add link to each trail page which would point to hiking.waymarkedtrails.org. For example on https://pss.rs/terenipp/staza-zdravlja-manastir-draca/ we would like to point to https://hiking.waymarkedtrails.org/#route?id=13938905 but to be able to show to user map centered around this trail, same as done when "Show on map" is clicked. Is it possible to do that with additional parameter without need to calculate map parameter externally ( https://hiking.waymarkedtrails.org/#route?id=13938905&map=16.0/44.0238/20.7826 ) or instruct user to click "Show on map" after page loads?

lonvia commented 2 years ago

This is a bug/regression in the website. A link without a map parameter should zoom to the route.

vanjakom commented 2 years ago

Works as expected, thanks!