How do I add a link that I don't want Discourse to expand?

I was trying to reply to Google Translate has trouble with this site - #2 by SomeoneElse and wanted my answer to just be the URL rather than whatever that URL expands to.

(interestingly Discourse didn’t expand ^^ link)

you have to make sure the link is not the only thing in the line.
e.g. https://www.osm.org

1 Like

That nearly worked - it works for most links, but doesn’t work for Discourse’s own links such as in my reply on Could we have a emoji :thumps up: as reaction? - #11 by SomeoneElse where it wasn’t the only thing on the line.

And of course in that sentence ^^ too!

I don’t see any previews on the messages your are referring to :thinking:

The URL in the last message was “ht tps://community.openstreetmap.org/t/could-we-have-a-emoji-thumps-up-as-reaction/708/11” (deliberately breaking the URL so that Discourse doesn’t munge it) but I don’t see that - instead I see “Could we have a emoji :thumps up: as reaction? - #11 by SomeoneElse 2”.

I think internal links are “beautified” if you just drop the url directly, but they are not if linked on a portion of text.

1 Like

Putting the link in angle brackets also works:

<https://community.openstreetmap.org/t/how-do-i-add-a-link-that-i-dont-want-discourse-to-expand/739> → https://community.openstreetmap.org/t/how-do-i-add-a-link-that-i-dont-want-discourse-to-expand/739

4 Likes

Exactly. And if you want, you can use the URL as the link text as well as the link target.

[https://community.openstreetmap.org/t/could-we-have-a-emoji-thumps-up-as-reaction/708/11](https://community.openstreetmap.org/t/could-we-have-a-emoji-thumps-up-as-reaction/708/11)

produces:

https://community.openstreetmap.org/t/could-we-have-a-emoji-thumps-up-as-reaction/708/11

Not as short as the angle brackets mentioned by @jleedev, but more intuitive to me because it follows the usual syntax for markdown links. (Works with the “Link” button in the graphical user interface as well.)