Make WordPress Core

Ticket #18984: 18984.2.diff

File 18984.2.diff, 2.1 KB (added by martythornley, 13 years ago)

Removed title from insert from other website js in addExtImage

  • wp-includes/media.php

     
    228228        $class = 'align' . esc_attr($align) .' size-' . esc_attr($size) . ' wp-image-' . $id;
    229229        $class = apply_filters('get_image_tag_class', $class, $id, $align, $size);
    230230
    231         $html = '<img src="' . esc_attr($img_src) . '" alt="' . esc_attr($alt) . '" title="' . esc_attr($title).'" '.$hwstring.'class="'.$class.'" />';
     231        $html = '<img src="' . esc_attr($img_src) . '" alt="' . esc_attr($alt) . '" '.$hwstring.'class="'.$class.'" />';
    232232
    233233        $html = apply_filters( 'get_image_tag', $html, $id, $alt, $title, $align, $size );
    234234
     
    660660                        'src'   => $src,
    661661                        'class' => "attachment-$size",
    662662                        'alt'   => trim(strip_tags( get_post_meta($attachment_id, '_wp_attachment_image_alt', true) )), // Use Alt field first
    663                         'title' => trim(strip_tags( $attachment->post_title )),
    664663                );
    665664                if ( empty($default_attr['alt']) )
    666665                        $default_attr['alt'] = trim(strip_tags( $attachment->post_excerpt )); // If not, Use the Caption
  • wp-admin/includes/media.php

     
    15191519                if ( '' == f.src.value || '' == t.width )
    15201520                        return false;
    15211521
    1522                 if ( f.title.value ) {
    1523                         title = f.title.value.replace(/'/g, '&#039;').replace(/"/g, '&quot;').replace(/</g, '&lt;').replace(/>/g, '&gt;');
    1524                         title = ' title="'+title+'"';
    1525                 }
    1526 
    15271522                if ( f.alt.value )
    15281523                        alt = f.alt.value.replace(/'/g, '&#039;').replace(/"/g, '&quot;').replace(/</g, '&lt;').replace(/>/g, '&gt;');
    15291524
     
    15401535
    15411536                cls = caption ? '' : ' class="'+t.align+'"';
    15421537
    1543                 html = '<img alt="'+alt+'" src="'+f.src.value+'"'+title+cls+' width="'+t.width+'" height="'+t.height+'" />';
     1538                html = '<img alt="'+alt+'" src="'+f.src.value+'"'+cls+' width="'+t.width+'" height="'+t.height+'" />';
    15441539
    15451540                if ( f.url.value ) {
    15461541                        url = f.url.value.replace(/'/g, '&#039;').replace(/"/g, '&quot;').replace(/</g, '&lt;').replace(/>/g, '&gt;');