Make WordPress Core


Ignore:
Timestamp:
09/29/2011 09:21:15 PM (13 years ago)
Author:
nacin
Message:

Add filter for the args into wp_dropdown_pages() in the page attributes box. Give the list_pages filter the context of the post object. fixes #8592 for 3.3.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/includes/class-wp-posts-list-table.php

    r18722 r18818  
    847847                <span class="title"><?php _e( 'Parent' ); ?></span>
    848848    <?php
    849         $dropdown_args = array( 'post_type' => $post_type_object->name, 'selected' => $post->post_parent, 'name' => 'post_parent', 'show_option_none' => __( 'Main Page (no parent)' ), 'option_none_value' => 0, 'sort_column'=> 'menu_order, post_title' );
     849        $dropdown_args = array(
     850            'post_type'         => $post_type_object->name,
     851            'selected'          => $post->post_parent,
     852            'name'              => 'post_parent',
     853            'show_option_none'  => __( 'Main Page (no parent)' ),
     854            'option_none_value' => 0,
     855            'sort_column'       => 'menu_order, post_title',
     856        );
     857
    850858        if ( $bulk )
    851859            $dropdown_args['show_option_no_change'] =  __( '&mdash; No Change &mdash;' );
Note: See TracChangeset for help on using the changeset viewer.