Opened 10 years ago
Last modified 8 years ago
#13669 confirmed New Feature
Improve the heuristic for URL recognition in autolink
Reported by: | Piotrek Koszuliński | Owned by: | |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | General | Version: | 4.5.0 Beta |
Keywords: | Cc: |
Description (last modified by )
Steps to reproduce
Based on https://twitter.com/l0c0luke/status/633684769121832960
Autolink will not recognise youtu.be/cSVuh_8-VQs as a link, hence autoembed will not find it too. Links without protocols are a common case as browsers hide them in the URL bar.
Expected result
We may try to improve the heuristic so it autolinks such URLs. It may happen that it will start autolinking too much, but links can always be removed, so it should not be a big problem as long as it's not happening for typical plain text.
Change History (3)
comment:1 Changed 10 years ago by
Description: | modified (diff) |
---|---|
Status: | new → confirmed |
Summary: | Improve heuristic for URL recognition in autolink → Improve the heuristic for URL recognition in autolink |
From what I have checked autolink will only work when you paste
http://o2.pl
but not when you pastetext http://o2.pl text
orhttp://o2.pl www.o2.pl test.com
. It only assumes that user pastes a link and nothing else.I personally think this is too strict and that we should allow more:
text http://o2.pl text
. We just need to remove^ $
from patternhttp(s)?
orwww.
as well?