Make WordPress Core


Ignore:
Timestamp:
04/24/2009 04:57:27 PM (17 years ago)
Author:
ryan
Message:

Silence html_entity_decode warnings. Props Denis-de-Bernardy. fixes #9616

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/import/blogger.php

    r10688 r11081  
    438438                                        foreach ( $matches[1] as $match )
    439439                                                if ( preg_match('/rel=.previous./', $match) )
    440                                                         $query = html_entity_decode( preg_replace('/^.*href=[\'"].*\?(.+)[\'"].*$/', '$1', $match), ENT_COMPAT, get_option('blog_charset') );
     440                                                        $query = @html_entity_decode( preg_replace('/^.*href=[\'"].*\?(.+)[\'"].*$/', '$1', $match), ENT_COMPAT, get_option('blog_charset') );
    441441
    442442                                if ( $query ) {
     
    496496                                        foreach ( $matches[1] as $match )
    497497                                                if ( preg_match('/rel=.previous./', $match) )
    498                                                         $query = html_entity_decode( preg_replace('/^.*href=[\'"].*\?(.+)[\'"].*$/', '$1', $match), ENT_COMPAT, get_option('blog_charset') );
     498                                                        $query = @html_entity_decode( preg_replace('/^.*href=[\'"].*\?(.+)[\'"].*$/', '$1', $match), ENT_COMPAT, get_option('blog_charset') );
    499499
    500500                                parse_str($query, $q);
     
    546546
    547547                $post_date    = $this->convert_date( $entry->published );
    548                 $post_content = trim( addslashes( $this->no_apos( html_entity_decode( $entry->content, ENT_COMPAT, get_option('blog_charset') ) ) ) );
     548                $post_content = trim( addslashes( $this->no_apos( @html_entity_decode( $entry->content, ENT_COMPAT, get_option('blog_charset') ) ) ) );
    549549                $post_title   = trim( addslashes( $this->no_apos( $this->min_whitespace( $entry->title ) ) ) );
    550550                $post_status  = isset( $entry->draft ) ? 'draft' : 'publish';
     
    601601                $comment_author_url = addslashes( $this->no_apos( strip_tags( (string) $matches[2] ) ) );
    602602                $comment_date    = $this->convert_date( $entry->updated );
    603                 $comment_content = addslashes( $this->no_apos( html_entity_decode( $entry->content, ENT_COMPAT, get_option('blog_charset') ) ) );
     603                $comment_content = addslashes( $this->no_apos( @html_entity_decode( $entry->content, ENT_COMPAT, get_option('blog_charset') ) ) );
    604604
    605605                // Clean up content
Note: See TracChangeset for help on using the changeset viewer.