OpenStreetMap 标志 OpenStreetMap

New major feature: Create your own links!

jgpacker 于 2020年七月17日 以 English 发布 最后一次更新于2020年七月22日。

Since OSM Smart Menu version 0.13, users can add their own links using an URL Template! Configuration form to add new links

For example, you can create links like:

  • https://geohack.toolforge.org/geohack.php?params={latitude}_N_{longitude}_E
  • https://disfactory.tw/#map={zoom}/{longitude}/{latitude}
  • and https://hiking.waymarkedtrails.org/#route?id={osm_relation_id}

Please give it a try! More information is available in the respective OpenStreetMap Wiki page!

电子邮件图标 Bluesky图标 Facebook图标 LinkedIn图标 Mastodon图标 Telegram图标 X图标

讨论

Tordanik2020年07月18日 18:09 的评论

This is a great feature, thank you! I expect myself to get a lot of mileage out of the various id parameters as well as osm_user_name. :)

Is there a chance that we’ll see additional bracket parameters in the future? For example, I often find myself switching between different pages for tags (i.e. key and value somewhere in the URL) as well as keys, and this seems like it would fit the concept.

jgpacker2020年07月20日 01:56 的评论

Great!

Yes, I am planning to add some other parameters like {bbox_min_latitude}.

I can also add {osm_tag_key} and/or {osm_tag_value} if they are useful. They were actually supported in the beginning of the project, but they were only used for OpenStreetMap Wiki and Taginfo (and both these websites already have links to each other), so they were removed.

Tordanik2020年07月21日 20:59 的评论

I can only speak for myself, but I’d find support for tags useful. In addition to the OSM Wiki and Taginfo, I’d also use the feature for Taghistory and Overpass Turbo, and I’d probably define a few links to frequently-used Taginfo subpages for my own use as well. (Overpass is one-way, sadly – you can get there with an URL containing a key and/or value, but it instantly forwards you to a different URL.)

Would the extension be able to understand that {osm_tag_key} can be used together with {osm_tag_value} as well as by itself? Or would there be a separate parameter for the key-only case vs. the key-of-a-tag case?

jgpacker2020年07月23日 18:59 的评论

Fair enough! I have added {osm_tag_key} and {osm_tag_value} in 0.14.2. I still am struggling to understand what should be in the default list of websites, so you will need to add wiki, taginfo and so on to be able to use them:

  • https://wiki.openstreetmap.org/wiki/Key:{osm_tag_key}
  • https://wiki.openstreetmap.org/wiki/Tag:{osm_tag_key}%3D{osm_tag_value}
  • https://taginfo.openstreetmap.org/keys/{osm_tag_key}
  • https://taginfo.openstreetmap.org/tags/{osm_tag_key}={osm_tag_value}

Please report any bug by a direct message or in Github. (e.g. URL encoding might be an issue at the moment).

About your question: {osm_tag_key} can be used by itself or with any other parameters. I am trying to make this as intuitive&flexible as possible.

Tordanik2020年07月24日 20:11 的评论

This is awesome, thanks a lot! I’ll make sure to drop by the issue tracker if I discover any bugs. So far it works like a charm!

登录以留下评论