Changeset 22409
- Timestamp:
- 11/06/2012 11:23:03 PM (12 years ago)
- Location:
- trunk
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-admin/includes/media.php
r22367 r22409 1528 1528 return false; 1529 1529 1530 if ( f.title.value ) {1531 title = f.title.value.replace(/'/g, ''').replace(/"/g, '"').replace(/</g, '<').replace(/>/g, '>');1532 title = ' title="'+title+'"';1533 }1534 1535 1530 if ( f.alt.value ) 1536 1531 alt = f.alt.value.replace(/'/g, ''').replace(/"/g, '"').replace(/</g, '<').replace(/>/g, '>'); … … 1549 1544 cls = caption ? '' : ' class="'+t.align+'"'; 1550 1545 1551 html = '<img alt="'+alt+'" src="'+f.src.value+'"'+ title+cls+' width="'+t.width+'" height="'+t.height+'" />';1546 html = '<img alt="'+alt+'" src="'+f.src.value+'"'+cls+' width="'+t.width+'" height="'+t.height+'" />'; 1552 1547 1553 1548 if ( f.url.value ) { -
trunk/wp-includes/media.php
r22362 r22409 229 229 $class = apply_filters('get_image_tag_class', $class, $id, $align, $size); 230 230 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.'" />'; 232 232 233 233 $html = apply_filters( 'get_image_tag', $html, $id, $alt, $title, $align, $size ); … … 549 549 'class' => "attachment-$size", 550 550 'alt' => trim(strip_tags( get_post_meta($attachment_id, '_wp_attachment_image_alt', true) )), // Use Alt field first 551 'title' => trim(strip_tags( $attachment->post_title )),552 551 ); 553 552 if ( empty($default_attr['alt']) )
Note: See TracChangeset
for help on using the changeset viewer.