[wp-hackers] Clickable links filter on FTP hostnames
otto at ottodestruct.com
Fri Dec 14 18:19:11 UTC 2012
Funnily enough, when I viewed your email in GMail, it did exactly the
same thing to your "ftp.example.com", in exactly the same way (adding
http:// to it and making it a link).
I don't know if you'd call this a bug, but it may be unexpected.
However, a large number of FTP sites are indeed webservers nowadays
too. Kinda makes sense.
On Fri, Dec 14, 2012 at 12:14 PM, David Anderson <david at wordshell.net> wrote:
> There's a default filter in WordPress (which eventually is found in the
> function _make_web_ftp_clickable_cb in wp-includes/formatting.php), which
> takes anything matching "<space>ftp.(the rest)" and turns it into a
> hyperlink beginning with http://
> This seems very wrong. It was wrong for me. It turned a line in which I was
> listing an FTP server:
> Host: ftp.example.com
> into this which gives an HTTP link and hence is wrong and/or gibberish:
> Host: <a href="http://ftp.example.com"
> I can't think of why you'd want, by default, to add http:// to detected
> hostnames beginning with "ftp." . But before I file a bug in Trac, does
> anyone know why that bit of code is in there (and on by default)? Am I
> missing something?
> WordShell - WordPress fast from the CLI -www.wordshell.net
> wp-hackers mailing list
> wp-hackers at lists.automattic.com
More information about the wp-hackers