Consistently use edit_posts_per_page. Props sorich87. fixes #14135
git-svn-id: http://svn.automattic.com/wordpress/trunk@17082 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
60a828c31f
commit
edd8ffdb68
|
@ -1894,6 +1894,10 @@ function screen_options($screen) {
|
||||||
else
|
else
|
||||||
$per_page = apply_filters( $option, $per_page );
|
$per_page = apply_filters( $option, $per_page );
|
||||||
|
|
||||||
|
// Back compat
|
||||||
|
if ( isset( $screen->post_type ) )
|
||||||
|
$per_page = apply_filters( 'edit_posts_per_page', $per_page, $screen->post_type );
|
||||||
|
|
||||||
$return = "<div class='screen-options'>\n";
|
$return = "<div class='screen-options'>\n";
|
||||||
if ( !empty($per_page_label) )
|
if ( !empty($per_page_label) )
|
||||||
$return .= "<input type='text' class='screen-per-page' name='wp_screen_options[value]' id='$option' maxlength='3' value='$per_page' /> <label for='$option'>$per_page_label</label>\n";
|
$return .= "<input type='text' class='screen-per-page' name='wp_screen_options[value]' id='$option' maxlength='3' value='$per_page' /> <label for='$option'>$per_page_label</label>\n";
|
||||||
|
|
Loading…
Reference in New Issue