WordPress.org

Make WordPress Core


Ignore:
Timestamp:
09/26/2012 08:50:13 PM (9 years ago)
Author:
koopersmith
Message:

Media JS: Add support for filtering Attachment collections by mime type. see #21390, #21776, #21809.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/includes/ajax-actions.php

    r21914 r22021  
    18031803function wp_ajax_query_attachments() {
    18041804    $query = isset( $_REQUEST['query'] ) ? (array) $_REQUEST['query'] : array();
    1805     $query = array_intersect_key( $query, array_flip( array( 's', 'order', 'orderby', 'posts_per_page', 'paged' ) ) );
     1805    $query = array_intersect_key( $query, array_flip( array( 's', 'order', 'orderby', 'posts_per_page', 'paged', 'post_mime_type' ) ) );
    18061806
    18071807    $query['post_type'] = 'attachment';
Note: See TracChangeset for help on using the changeset viewer.