szmer
  • Communities
  • Create Post
  • Create Community
  • heart
    Support Lemmy
  • search
    Search
  • Login
  • Sign Up
Tom Violence@lemmy.one to Asklemmy@lemmy.mlEnglish ·
edit-2
2 years ago

Is there a way to make instance-agnostic links?

message-square
message-square
11
fedilink
12
message-square

Is there a way to make instance-agnostic links?

Tom Violence@lemmy.one to Asklemmy@lemmy.mlEnglish ·
edit-2
2 years ago
message-square
11
fedilink

Is there a way to make a link to a community of a foreign instance that opens on the instance of the user that clicks on it?

For example, I would like to make a link to !some_community@foo.com that, when a user of bar.com clicks on it, opens https://bar.com/c/some_community@foo.com instead of https://foo.com/c/some_community.

If it’s not possible, don’t you think it would be convenient?

alert-triangle
You must log in or # to comment.
  • boomboxnation@beehaw.org
    link
    fedilink
    English
    arrow-up
    3
    ·
    edit-2
    2 years ago
    [Some text here](community@instance.here)
    

    Tap the ‘more’ skinny hamburger menu just above below this message to ‘view source’ of the below:

    blah blah blah links to asklemmy@lemmy.ml

    Actually…better, here is one for an instance that is neither yours or the one you posted into:

    blay harg vlar

    • Tom Violence@lemmy.oneOP
      link
      fedilink
      English
      arrow-up
      1
      ·
      2 years ago

      That’s perfect! Thank you :)

    • gingerman@lemmy.ca
      link
      fedilink
      English
      arrow-up
      1
      ·
      2 years ago

      Should these links work? I’m viewing this thread from Lemmy.ca and both give me a 404 error. When testing with jerboa, the app crashes

  • fubo@lemmy.world
    link
    fedilink
    English
    arrow-up
    2
    ·
    edit-2
    2 years ago

    Yes, you can do this using a relative URL!

    Here’s an example.

    Here’s how I wrote it:

    [Here's an example.](/c/asklemmy@lemmy.ml)

    Because this URL doesn’t have a protocol or a domain, your browser fills those in from the URL of the page you’re on when you see it. Since that’s on your local Lemmy instance, you’ll see a link to !asklemmy@lemmy.ml on that instance.

    Also: When you’re looking at a Lemmy comment, if you don’t know how the author wrote the markup for it, you can use the “view source” button underneath the “…” menu.


    Note: These links will NOT work between Lemmy and Kbin, because Kbin uses /m/ instead of /c/.

  • melonpunk@lemmy.world
    link
    fedilink
    English
    arrow-up
    1
    ·
    edit-2
    2 years ago

    I’d like to know too. I was hoping it would be something simple like !community@host.com which would resolve for everyone. Didn’t work when I tried it, though I might not have done it correctly.

    EDIT: I guess I could try again here !asklemmy@lemmy.ml

    EDIT2: Nope: That link goes to https://lemmy.world/post/!asklemmy@lemmy.ml for me, which is not valid.

    • dill@lemmy.one
      link
      fedilink
      English
      arrow-up
      2
      ·
      2 years ago

      That link crashes jerboa lol

  • Catsrules@lemmy.ml
    link
    fedilink
    English
    arrow-up
    1
    ·
    edit-2
    2 years ago

    Edit Sorry I misunderstood. You can link the community, but posts I don’t believe you can.

    There isn’t a way at the moment. Solutions to this are being discussed on Github

    https://github.com/LemmyNet/lemmy-ui/issues/1048

  • Perhyte@lemmy.world
    link
    fedilink
    English
    arrow-up
    1
    ·
    edit-2
    2 years ago

    Once your Lemmy web frontend upgrades to version 0.18, the following should all auto-link with no extra syntax:

    • !community@server.com
    • /c/community@server.com
    • /m/community@server.com
    • /u/username@server.com

    These should then all link to the instance you’re currently on.

    Note: because this is implemented in the frontend and does not change the underlying data, other Fediverse clients will not show these the same unless they also implement this themselves.

    • Tom Violence@lemmy.oneOP
      link
      fedilink
      English
      arrow-up
      1
      ·
      2 years ago

      Nice, thanks for the info!

  • jrubal1462@kbin.social
    link
    fedilink
    arrow-up
    1
    ·
    2 years ago

    I thought it worked if you just linked /c/asklemmy@lemmy.ml
    With the only caveat being that users on kbin will need /m/asklemmy.ml

    I would normally test the crap out of these before posting since I really don’t know what I’m doing, but I’m on my phone and mostly busy at the moment. Sorry if it doesn’t work.

Asklemmy@lemmy.ml

asklemmy@lemmy.ml

Subscribe from Remote Instance

Create a post
You are not logged in. However you can subscribe from another Fediverse account, for example Lemmy or Mastodon. To do this, paste the following into the search field of your instance: !asklemmy@lemmy.ml

A loosely moderated place to ask open-ended questions

Search asklemmy 🔍

If your post meets the following criteria, it’s welcome here!

  1. Open-ended question
  2. Not offensive: at this point, we do not have the bandwidth to moderate overtly political discussions. Assume best intent and be excellent to each other.
  3. Not regarding using or support for Lemmy: context, see the list of support communities and tools for finding communities below
  4. Not ad nauseam inducing: please make sure it is a question that would be new to most members
  5. An actual topic of discussion

Looking for support?

  • !lemmy_support@lemmy.ml
  • !fediverse@lemmy.ml
  • !selfhosted@lemmy.world

Looking for a community?

  • Lemmyverse: community search
  • sub.rehab: maps old subreddits to fediverse options, marks official as such
  • !lemmy411@lemmy.ca: a community for finding communities

Icon by @Double_A@discuss.tchncs.de

Visibility: Public
globe

This community can be federated to other instances and be posted/commented in by their users.

  • 947 users / day
  • 2.69K users / week
  • 5.8K users / month
  • 18.2K users / 6 months
  • 40 local subscribers
  • 49.4K subscribers
  • 7.74K Posts
  • 364K Comments
  • Modlog
  • mods:
  • Evan@lemmy.ml
  • mekhos@lemmy.ml
  • tmpod@lemmy.pt
  • OrangeSlice@lemmy.ml
  • BE: 0.19.6
  • Modlog
  • Legal
  • Instances
  • Docs
  • Code
  • join-lemmy.org