Make WordPress Core

Ticket #11734: 11734.diff

File 11734.diff, 1.4 KB (added by mdawaffe, 10 years ago)
  • wp-includes/comment-template.php

     
    746746        if ( false !== stripos($_SERVER['HTTP_USER_AGENT'], 'W3C_Validator') )
    747747                return;
    748748
    749         echo '<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
     749        $permalink = apply_filters( 'the_permalink', get_permalink() );
     750
     751        $output  = '<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
    750752                        xmlns:dc="http://purl.org/dc/elements/1.1/"
    751753                        xmlns:trackback="http://madskills.com/public/xml/rss/module/trackback/">
    752754                <rdf:Description rdf:about="';
    753         the_permalink();
    754         echo '"'."\n";
    755         echo '    dc:identifier="';
    756         the_permalink();
    757         echo '"'."\n";
    758         echo '    dc:title="'.str_replace('--', '&#x2d;&#x2d;', wptexturize(strip_tags(get_the_title()))).'"'."\n";
    759         echo '    trackback:ping="'.get_trackback_url().'"'." />\n";
    760         echo '</rdf:RDF>';
     755        $output .= esc_url( $permalink );
     756        $output .= '"'."\n";
     757        $output .= '    dc:identifier="';
     758        $output .= esc_url( $permalink );
     759        $output .= '"'."\n";
     760        $output .= '    dc:title="' . esc_attr( strip_tags( get_the_title() ) ) . '"' . "\n";
     761        $output .= '    trackback:ping="' . esc_url( get_trackback_url() ) . '"' . " />\n";
     762        $output .= '</rdf:RDF>';
     763
     764        echo str_replace( '--', '&#x2d;&#x2d;', $output );
    761765}
    762766
    763767/**