3 ms·
To avoid this issue when writing URLs in plaintext, I add a space at the end. > Check out https://example.com/thing https://example.com/thing . They've got...
by ademarre 6y ago
To avoid this issue when writing URLs in plaintext, I add a space at the end.
> Check out https://example.com/thing https://example.com/thing . They've got...
Let's say we were serious about solving this problem (without adopting a strategy like mine above). We would need a set of rules for plaintext-safe URLs. It would comprise:
- An extension to the URL syntax to specify the subset of URLs that are plaintext safe. It might be as simple as a list of punctuation characters that cannot appear at the end of a URL (unless they are percent encoded).
- Guidelines and test vectors for implementers of URL identification algorithms.
- Guidelines for content authors. E.g., "The only characters that may immediately follow a URL are..."
- A recommendation for web developers to ensure plaintext safefy when creating new URLs.
- fanf2 6y agoThere's already RFC 3986 appendix C https://tools.ietf.org/html/rfc3986#appendix-C https://tools.ietf.org/html/rfc3986#appendix-C but delimiting UTLs with <> has gone out of fashion, and sometimes is not supported. e.g. hacker news gets it wrong by counting the > as part of the URL even though it isn't a valid URL character.