Changeset 28194 for trunk/src/wp-includes/media.php
- Timestamp:
- 04/24/2014 11:54:31 AM (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/media.php
r28191 r28194 2657 2657 return; 2658 2658 2659 global $content_width ;2659 global $content_width, $wpdb; 2660 2660 2661 2661 $defaults = array( … … 2695 2695 } 2696 2696 } 2697 2698 $has_audio = $wpdb->get_var( " 2699 SELECT ID 2700 FROM $wpdb->posts 2701 WHERE post_type = 'attachment' 2702 AND post_mime_type LIKE 'audio%' 2703 LIMIT 1 2704 " ); 2705 $has_video = $wpdb->get_var( " 2706 SELECT ID 2707 FROM $wpdb->posts 2708 WHERE post_type = 'attachment' 2709 AND post_mime_type LIKE 'video%' 2710 LIMIT 1 2711 " ); 2697 2712 2698 2713 $settings = array( … … 2710 2725 'defaultProps' => $props, 2711 2726 'attachmentCounts' => array( 2712 'audio' => wp_has_mime_type_attachments( 'audio') ? 1 : 0,2713 'video' => wp_has_mime_type_attachments( 'video') ? 1 : 02727 'audio' => ( $has_audio ) ? 1 : 0, 2728 'video' => ( $has_video ) ? 1 : 0 2714 2729 ), 2715 2730 'embedExts' => $exts,
Note: See TracChangeset
for help on using the changeset viewer.