Make WordPress Core

Ticket #22946: 22946.diff

File 22946.diff, 470 bytes (added by mdgl, 8 years ago)
  • wp-includes/formatting.php

     
    16461646function _make_web_ftp_clickable_cb($matches) {
    16471647        $ret = '';
    16481648        $dest = $matches[2];
    1649         $dest = 'http://' . $dest;
     1649        $dest = ( $matches[3] == 'ftp' ? 'ftp://' : 'http://' ) . $dest;
    16501650        $dest = esc_url($dest);
    16511651        if ( empty($dest) )
    16521652                return $matches[0];