WordPress.org

Make WordPress Core

Ticket #21914: pingback_ping.diff

File pingback_ping.diff, 791 bytes (added by Otto42, 3 years ago)

minor enhancement to the pingback parsing

  • wp-includes/class-wp-xmlrpc-server.php

     
    53205320                // Work around bug in strip_tags(): 
    53215321                $linea = str_replace('<!DOC', '<DOC', $linea); 
    53225322                $linea = preg_replace( '/[\s\r\n\t]+/', ' ', $linea ); // normalize spaces 
    5323                 $linea = preg_replace( "/ <(h1|h2|h3|h4|h5|h6|p|th|td|li|dt|dd|pre|caption|input|textarea|button|body)[^>]*>/", "\n\n", $linea ); 
     5323                $linea = preg_replace( "/<\/*(h1|h2|h3|h4|h5|h6|p|th|td|li|dt|dd|pre|caption|input|textarea|button|body)[^>]*>/", "\n\n", $linea ); 
    53245324 
    53255325                preg_match('|<title>([^<]*?)</title>|is', $linea, $matchtitle); 
    53265326                $title = $matchtitle[1];