Changeset 11964 for trunk/wp-admin/import/livejournal.php
- Timestamp:
- 09/23/2009 10:03:39 PM (17 years ago)
- File:
-
- 1 edited
-
trunk/wp-admin/import/livejournal.php (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-admin/import/livejournal.php
r11383 r11964 325 325 } 326 326 327 function _normalize_tag( $matches ) { 328 return '<' . strtolower( $match[1] ); 329 } 330 327 331 function import_post( $post ) { 328 332 global $wpdb; … … 351 355 // Clean up content 352 356 $post_content = $post['event']; 353 $post_content = preg_replace_callback( '|<(/?[A-Z]+)|', create_function( '$match', 'return "<" . strtolower( $match[1] );' ), $post_content );357 $post_content = preg_replace_callback( '|<(/?[A-Z]+)|', array( &$this, '_normalize_tag' ), $post_content ); 354 358 // XHTMLize some tags 355 359 $post_content = str_replace( '<br>', '<br />', $post_content ); … … 582 586 $comment_content = str_replace( '<br>', '<br />', $comment_content ); 583 587 $comment_content = str_replace( '<hr>', '<hr />', $comment_content ); 584 $comment_content = preg_replace_callback( '|<(/?[A-Z]+)|', create_function( '$match', 'return "<" . strtolower( $match[1] );' ), $comment_content );588 $comment_content = preg_replace_callback( '|<(/?[A-Z]+)|', array( &$this, '_normalize_tag' ), $comment_content ); 585 589 $comment_content = $wpdb->escape( trim( $comment_content ) ); 586 590
Note:
See TracChangeset
for help on using the changeset viewer.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)