[wp-trac] [WordPress Trac] #7844: WP sends urlencode text in pingback/trackback

WordPress Trac wp-trac at lists.automattic.com
Wed Oct 8 02:28:31 GMT 2008


#7844: WP sends urlencode text in pingback/trackback
---------------------+------------------------------------------------------
 Reporter:  reinkim  |       Owner:  anonymous                  
     Type:  defect   |      Status:  new                        
 Priority:  normal   |   Milestone:  2.7                        
Component:  General  |     Version:  2.7                        
 Severity:  major    |    Keywords:  trackback,pingback,HTTP api
---------------------+------------------------------------------------------
 From [9012], WP sends trackback/pingback using urlencoded text.

 [9012] introduces HTTP api to send trackback/pingback. But in this
 changeset, WP sends blog-title, uri and excerpt in url-encoded format.
 So pinged/trackbacked blog displays some strangely formatted trackback
 like,

 {{{
 blog+title // title
 http%3A%2F%2Fexample.org%2F111 // uri
 blah+blah+blah+%23%21%40%23%24 // excerpt
 }}}

 This behavior is caused by passing arguments of HTTP api in urlencoded
 text. (wp-includes/comment.php:1312)

 To fix this problem, I've patched current working version of trunk like
 following diff.
 {{{
 #!diff
 --- comment.php (revision 9098)
 +++ comment.php (working copy)
 @@ -1310,10 +1310,10 @@
     $options = array();
     $options['timeout'] = 4;
     $options['body'] = array(
 -       'title' => urlencode($title),
 -       'url' => urlencode(get_permalink($ID)),
 -       'blog_name' => urlencode(get_option('blogname')),
 -       'excerpt' => urlencode($excerpt)
 +       'title' => $title,
 +       'url' => get_permalink($ID),
 +       'blog_name' => get_option('blogname'),
 +       'excerpt' => $excerpt
     );
 }}}

-- 
Ticket URL: <http://trac.wordpress.org/ticket/7844>
WordPress Trac <http://trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list