Changeset 5038
- Timestamp:
- 03/14/2007 07:20:19 PM (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-admin/import/blogger.php
r4990 r5038 85 85 $headers = array( 86 86 "GET /feeds/default/blogs HTTP/1.0", 87 "Host: www .blogger.com",87 "Host: www2.blogger.com", 88 88 "Authorization: AuthSub token=\"$this->token\"" 89 89 ); … … 548 548 549 549 $comment_post_ID = $this->blogs[$importing_blog]['posts'][$entry->old_post_permalink]; 550 $comment_author = addslashes( $this->no_apos( strip_tags( $entry->author ) ) ); 550 preg_match('#<name>(.+?)</name>.*(?:\<uri>(.+?)</uri>)?#', $entry->author, $matches); 551 $comment_author = addslashes( $this->no_apos( strip_tags( (string) $matches[1] ) ) ); 552 $comment_author_url = addslashes( $this->no_apos( strip_tags( (string) $matches[2] ) ) ); 551 553 $comment_date = $this->convert_date( $entry->updated ); 552 554 $comment_content = addslashes( $this->no_apos( html_entity_decode( $entry->content ) ) ); … … 564 566 ++$this->blogs[$importing_blog]['comments_skipped']; 565 567 } else { 566 $comment = compact('comment_post_ID', 'comment_author', 'comment_ date', 'comment_content');568 $comment = compact('comment_post_ID', 'comment_author', 'comment_author_url', 'comment_date', 'comment_content'); 567 569 568 570 $comment_id = wp_insert_comment($comment); … … 673 675 } 674 676 675 function _get_blogger_sock($host = 'www .blogger.com') {677 function _get_blogger_sock($host = 'www2.blogger.com') { 676 678 if ( !$sock = @ fsockopen($host, 80, $errno, $errstr) ) { 677 679 $this->uh_oh(
Note: See TracChangeset
for help on using the changeset viewer.