automatic links within backticks not escaped properly
Michel Fortin
michel.fortin at michelf.com
Tue Nov 30 23:36:46 EST 2004
Le 30 nov. 2004, à 12:38, Tim Pritlove a écrit :
> Can you explain what you'd call a "proper" protocol? Is it that just
> "well-known" protocols are detected? Or is it that "any word followed
> by a colon" is detected?
>
> I am actually using a _lot_ of different protocols (including some
> used only in our own projects) like afp, smb, ssh, scp, blp etc. pp.
Well, currently, it supports "http", "https", "ftp", and "mailto". If
you want to write an URL with any other protocol you would have to
write the link using the normal link syntax. This is:
[ftps://example.bip/](ftps://example.bip/)
I will be the first to recognize this is not nice.
Since it is almost impossible to catch every url scheme in a reliable
manner, and also because it is mostly impractical to write thing like
above, I would like to suggest an alternate URL syntax that could work
for any protocol, even if unknown to Markdown.
The trick is to append `URL:` in front of the URL so Markdown knows for
sure what it is. What is interesting is that it is based on the syntax
found inside [RFC 1738][1] named "Uniform Resource Locators".
<URL:afp://example.bip/>
<URL:ftps://example.bip/>
Of course the old way would still work for protocols Markdown knows
about. It's just a practical addition if you use less-known ones.
[1]: http://www.ietf.org/rfc/rfc1738.txt
Michel Fortin
michel.fortin at michelf.com
http://www.michelf.com/
More information about the Markdown-discuss
mailing list