mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-05-21 11:44:36 +00:00
Screen Options: Improve items per page option label.
Previously the label just said "Posts", "Pages", or "Comments". This was bad in terms of accessibility and internationalization because of missing context. This change adds a default label "Number of items per page:" to `WP_Screen->render_per_page_options()` and removes all the existing one-word labels. props afercia. fixes #31349, #15576. git-svn-id: https://develop.svn.wordpress.org/trunk@31696 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -29,7 +29,7 @@ function confirm_delete_users( $users ) {
|
||||
<?php else : ?>
|
||||
<p><?php _e( 'You have chosen to delete the user from all networks and sites.' ); ?></p>
|
||||
<?php endif; ?>
|
||||
|
||||
|
||||
<form action="users.php?action=dodelete" method="post">
|
||||
<input type="hidden" name="dodelete" />
|
||||
<?php
|
||||
@@ -108,11 +108,11 @@ function confirm_delete_users( $users ) {
|
||||
<?php else : ?>
|
||||
<p><?php _e( 'Once you hit “Confirm Deletion”, the user will be permanently removed.' ); ?></p>
|
||||
<?php endif;
|
||||
|
||||
|
||||
submit_button( __('Confirm Deletion'), 'delete' );
|
||||
?>
|
||||
</form>
|
||||
<?php
|
||||
<?php
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -136,8 +136,8 @@ if ( isset( $_GET['action'] ) ) {
|
||||
echo '<div class="wrap">';
|
||||
confirm_delete_users( $_POST['allusers'] );
|
||||
echo '</div>';
|
||||
require_once( ABSPATH . 'wp-admin/admin-footer.php' );
|
||||
} else {
|
||||
require_once( ABSPATH . 'wp-admin/admin-footer.php' );
|
||||
} else {
|
||||
wp_redirect( network_admin_url( 'users.php' ) );
|
||||
}
|
||||
exit();
|
||||
@@ -252,7 +252,7 @@ if ( $pagenum > $total_pages && $total_pages > 0 ) {
|
||||
$title = __( 'Users' );
|
||||
$parent_file = 'users.php';
|
||||
|
||||
add_screen_option( 'per_page', array('label' => _x( 'Users', 'users per page (screen options)' )) );
|
||||
add_screen_option( 'per_page' );
|
||||
|
||||
get_current_screen()->add_help_tab( array(
|
||||
'id' => 'overview',
|
||||
|
||||
Reference in New Issue
Block a user