Changeset 24547 for trunk/wp-admin/includes/media.php
- Timestamp:
- 07/03/2013 08:19:00 PM (13 years ago)
- File:
-
- 1 edited
-
trunk/wp-admin/includes/media.php (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-admin/includes/media.php
r24446 r24547 2358 2358 elseif ( $attachment_id && 0 === strpos( $post->post_mime_type, 'audio/' ) ): 2359 2359 2360 echo do_shortcode( '[audio src="' . $att_url . '"]');2360 echo wp_audio_shortcode( array( 'src' => $att_url ) ); 2361 2361 2362 2362 elseif ( $attachment_id && 0 === strpos( $post->post_mime_type, 'video/' ) ): … … 2370 2370 $h = round( ( $meta['height'] * $w ) / $meta['width'] ); 2371 2371 2372 $shortcode = sprintf( '[video src="%s"%s%s]', 2373 $att_url, 2374 empty( $meta['width'] ) ? '' : sprintf( ' width="%d"', $w ), 2375 empty( $meta['height'] ) ? '' : sprintf( ' height="%d"', $h ) 2376 ); 2377 echo do_shortcode( $shortcode ); 2372 $attr = array( 'src' => $att_url ); 2373 2374 if ( ! empty( $meta['width' ] ) ) 2375 $attr['width'] = $w; 2376 2377 if ( ! empty( $meta['height'] ) ) 2378 $attr['height'] = $h; 2379 2380 echo wp_video_shortcode( $attr ); 2378 2381 2379 2382 endif; ?>
Note: See TracChangeset
for help on using the changeset viewer.