[wp-hackers] Clickable links filter on FTP hostnames
David Anderson
david at wordshell.net
Fri Dec 14 18:14:28 UTC 2012
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"
rel="nofollow">http://ftp.example.com</a>
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?
David
--
WordShell - WordPress fast from the CLI -www.wordshell.net
More information about the wp-hackers
mailing list