Make the number of taxonomies to display per page setting actually stick. props nacin. fixes #13899
git-svn-id: http://svn.automattic.com/wordpress/trunk@15263 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
95746a960a
commit
e3d5fb602b
|
@ -249,12 +249,7 @@ $pagenum = isset( $_GET['pagenum'] ) ? absint( $_GET['pagenum'] ) : 0;
|
|||
if ( empty($pagenum) )
|
||||
$pagenum = 1;
|
||||
|
||||
if ( 'post_tag' == $taxonomy )
|
||||
$tags_per_page = (int) get_user_option( 'edit_tags_per_page' );
|
||||
elseif ( 'category' == $taxonomy )
|
||||
$tags_per_page = (int) get_user_option( 'categories_per_page' );
|
||||
else
|
||||
$tags_per_page = (int) get_user_option( 'edit_' . $taxonomy . '_per_page' );
|
||||
$tags_per_page = (int) get_user_option( 'edit_' . $taxonomy . '_per_page' );
|
||||
|
||||
if ( empty($tags_per_page) || $tags_per_page < 1 )
|
||||
$tags_per_page = 20;
|
||||
|
|
|
@ -337,6 +337,9 @@ function set_screen_options() {
|
|||
$type = str_replace('_per_page', '', $type);
|
||||
if ( in_array($type, get_post_types()) )
|
||||
$map_option = 'edit_per_page';
|
||||
if ( in_array( $type, get_taxonomies()) )
|
||||
$map_option = 'edit_tags_per_page';
|
||||
|
||||
|
||||
switch ( $map_option ) {
|
||||
case 'edit_per_page':
|
||||
|
@ -344,7 +347,6 @@ function set_screen_options() {
|
|||
case 'ms_users_per_page':
|
||||
case 'edit_comments_per_page':
|
||||
case 'upload_per_page':
|
||||
case 'categories_per_page':
|
||||
case 'edit_tags_per_page':
|
||||
case 'plugins_per_page':
|
||||
$value = (int) $value;
|
||||
|
|
|
@ -440,7 +440,7 @@ function upgrade_all() {
|
|||
if ( $wp_current_db_version < 11958 )
|
||||
upgrade_290();
|
||||
|
||||
if ( $wp_current_db_version < 15187 )
|
||||
if ( $wp_current_db_version < 15260 )
|
||||
upgrade_300();
|
||||
|
||||
maybe_disable_automattic_widgets();
|
||||
|
@ -1133,7 +1133,7 @@ function upgrade_300() {
|
|||
if ( !is_multisite() || is_main_site() ) {
|
||||
$prefix = like_escape($wpdb->base_prefix);
|
||||
$wpdb->query( "DELETE FROM $wpdb->usermeta WHERE meta_key LIKE '{$prefix}%meta-box-hidden%' OR meta_key LIKE '{$prefix}%closedpostboxes%' OR meta_key LIKE '{$prefix}%manage-%-columns-hidden%' OR meta_key LIKE '{$prefix}%meta-box-order%' OR meta_key LIKE '{$prefix}%metaboxorder%' OR meta_key LIKE '{$prefix}%screen_layout%'
|
||||
OR meta_key = 'manageedittagscolumnshidden' OR meta_key='managecategoriescolumnshidden' OR meta_key = 'manageedit-tagscolumnshidden' OR meta_key = 'manageeditcolumnshidden'" );
|
||||
OR meta_key = 'manageedittagscolumnshidden' OR meta_key='managecategoriescolumnshidden' OR meta_key = 'manageedit-tagscolumnshidden' OR meta_key = 'manageeditcolumnshidden' OR meta_key = 'categories_per_page' OR meta_key = 'edit_tags_per_page'" );
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -8,14 +8,14 @@
|
|||
*
|
||||
* @global string $wp_version
|
||||
*/
|
||||
$wp_version = '3.0-RC3-15257';
|
||||
$wp_version = '3.0-RC3-15260';
|
||||
|
||||
/**
|
||||
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
||||
*
|
||||
* @global int $wp_db_version
|
||||
*/
|
||||
$wp_db_version = 15187;
|
||||
$wp_db_version = 15260;
|
||||
|
||||
/**
|
||||
* Holds the TinyMCE version
|
||||
|
|
Loading…
Reference in New Issue