For each example in this post, I will be linking to the sea otter pools at the Vancouver aquarium. That location has the coordinates of 49.30063,-123.13149

To link to it, you would use ‘geo:49.30063,-123.13149’.

Depending on your web browser, pasting that into the search bar might prompt you to select which map website you want to use to view that location. For me in Firefox, it asked me to pick between Google Maps and OpenStreetMaps. It’s even more convenient on mobile, where it asks me which map app I want to open it with. Both CoMaps and Google Maps handled it correctly.

If you are writing a post or comment on Lemmy/Piefed/etc., you can place it in the second part of the markdown link format: [Sea Otter Pools](geo:49.30063,-123.13149). This would output like this: Sea Otter Pools

The linked OpenStreetMap wiki page has a good summary of how well various apps support this scheme. A lot of people here are active in the open source space, so please consider following up with the apps that are currently missing support or have partial support for this: https://wiki.openstreetmap.org/wiki/Geo_URI_scheme


EDIT: I forgot to mention, you can also use apps like this one to convert maps links between each other

https://github.com/jakubvalenta/GeoShare

https://f-droid.org/packages/page.ooooo.geoshare/

https://apt.izzysoft.de/fdroid/index/apk/page.ooooo.geoshare

  • GTG3000@programming.dev
    link
    fedilink
    English
    arrow-up
    5
    ·
    2 days ago

    Doesn’t do anything as far as I can tell? Or is this android specific?

    Also the links don’t work in discord.

    • gwl [he/him]@lemmy.blahaj.zone
      link
      fedilink
      English
      arrow-up
      5
      ·
      2 days ago

      It’s what’s known as a “Protocol URI”, which the OS and/or browser have to choose what to do with that

      Sounds like you have an OS or Browser that haven’t implemented the protocol

    • zekad@sh.itjust.works
      link
      fedilink
      English
      arrow-up
      1
      ·
      16 hours ago

      Gotta marvel at the logic at work. No one supports it, neither should we. Great way to ensure nothing ever happens.

    • unexposedhazard@discuss.tchncs.de
      link
      fedilink
      English
      arrow-up
      39
      ·
      3 days ago

      Same with element. They used to support it but dropped it. Really stupid excuse in that github issue. If adding support for sonething so simple adds lots of complexity then your codebase is garbage. This is why we cant have nice things.

      • Ghoelian@piefed.social
        link
        fedilink
        English
        arrow-up
        6
        ·
        3 days ago

        Lol the pr is only 2 files, one of which is a test class. I do wonder why they wrote their own parser, does javas url handler not support the geo scheme either or something?

  • lawks@aussie.zone
    link
    fedilink
    English
    arrow-up
    38
    ·
    3 days ago

    It has abysmal support. All the places you’d need it to work without anything special, like link recognition in messaging apps and email clients, it rarely does. Even apps that could make good use of specific locations for inputs often don’t register a handler for the scheme. It’s been that way for years, and I don’t expect it to get a whole lot better.

    • pet the cat, walk the dog@lemmy.world
      link
      fedilink
      English
      arrow-up
      3
      ·
      2 days ago

      Pro tip: on Android, the Automate app can receive text shared to it and do custom things — such as getting coordinates, slapping ‘geo:’ on them, and opening in a map app. This can alleviate some of the pains by the user selecting and sharing the coords by hand. The app is paid and requires some programming chops, but is hella useful for custom automation.

  • cloudsurfer@feddit.org
    link
    fedilink
    English
    arrow-up
    3
    ·
    2 days ago

    Does anyone know, why GitHub of all places does not support geo links in their readme or issue markdown files?

    • filcuk@feddit.uk
      link
      fedilink
      English
      arrow-up
      2
      ·
      2 days ago

      Mailto is explicitly allowed in the sanitizer they use, other such uri schemes aren’t.
      This is relatively standard, likely due to the mixed support.
      Geo is not well supported, and ones like sms are platform-dependent.
      It’s just a pain noone wants to deal with.

  • DougPiranha42@lemmy.world
    link
    fedilink
    English
    arrow-up
    19
    arrow-down
    1
    ·
    3 days ago

    This sounds nice. On iphone, nothing happens when I click your link. When I paste it in safari, it searches for it, and the ddg results are coordinates finder websites, not related to the specific location.

    • CombatWombat@feddit.online
      link
      fedilink
      English
      arrow-up
      6
      ·
      3 days ago

      This is only true if you don’t have an app installed to handle the link schema. When I click the link, it opens Organic Maps

      • friend_of_satan@lemmy.world
        link
        fedilink
        English
        arrow-up
        2
        ·
        2 days ago

        I’m trying to say “great job pointing that out” without soundling like an LLM. But seriously, I’m happy you pointed that out. I completely forgot about those syntaxes. After you mentioned them, I went and browsed RFC3986 and found these sample URIs, which include news, mailto, ftp, and more, which covers both // style and non-// style. https://www.rfc-editor.org/info/rfc3986/#section-1.1.2

        It’s too late for me to claim that I fully grok the nuances, so that’ll have to wait for anther day, but I appreciate your comment. TIL some cool stuff.

      • friend_of_satan@lemmy.world
        link
        fedilink
        English
        arrow-up
        2
        ·
        2 days ago

        maybe geo:earth.surface/lat,lon?date=date or geo:mars.sky?lat=lat,lon=lon,date=date or something? I’m sure there could be a stanard syntax for but I’m pretty ignorant about how that could work well.

  • deltapi@lemmy.world
    link
    fedilink
    English
    arrow-up
    11
    ·
    3 days ago

    Very cool, this was the result for me, so at least on android it seems to work as advertised. A picture of an app choice dialog after checking on a 'geo' link showing several map/location apps to choose from

    • Otter@lemmy.caOP
      link
      fedilink
      English
      arrow-up
      1
      ·
      3 days ago

      Oops 😄

      I think if you clear the cache it might go away. Mine doesn’t show it anymore

    • bampop@lemmy.world
      link
      fedilink
      English
      arrow-up
      1
      ·
      3 days ago

      For me in Firefox it just takes me to my search engine, which proposes a bunch of sites to convert gps coordinates, top item is a front end for google maps. No OpenStreetMaps to be seen. Doesn’t look like it’s a universally supported thing. Also none of the position links in this thread are clickable