X-Git-Url: https://scripts.mit.edu/gitweb/autoinstalls/wordpress.git/blobdiff_plain/7f1521bf193b382565eb753043c161f4cb3fcda7..febc815b2c9d85be5717da9e8d164bd2daa97e31:/wp-admin/upload.php?ds=inline diff --git a/wp-admin/upload.php b/wp-admin/upload.php index 39fa165f..b9495ac0 100644 --- a/wp-admin/upload.php +++ b/wp-admin/upload.php @@ -10,7 +10,7 @@ require_once( dirname( __FILE__ ) . '/admin.php' ); if ( !current_user_can('upload_files') ) - wp_die( __( 'You do not have permission to upload files.' ) ); + wp_die( __( 'Sorry, you are not allowed to upload files.' ) ); $mode = get_user_option( 'media_library_mode', get_current_user_id() ) ? get_user_option( 'media_library_mode', get_current_user_id() ) : 'grid'; $modes = array( 'grid', 'list' ); @@ -25,6 +25,8 @@ if ( 'grid' === $mode ) { wp_enqueue_script( 'media-grid' ); wp_enqueue_script( 'media' ); + remove_action( 'admin_head', 'wp_admin_canonical_url' ); + $q = $_GET; // let JS handle this unset( $q['s'] ); @@ -71,16 +73,20 @@ if ( 'grid' === $mode ) { require_once( ABSPATH . 'wp-admin/admin-header.php' ); ?>
count( $post_ids ), 'ids' => join( ',', $post_ids ) ), $location ); break; @@ -138,10 +144,10 @@ if ( $doaction ) { break; foreach ( (array) $post_ids as $post_id ) { if ( !current_user_can( 'delete_post', $post_id ) ) - wp_die( __( 'You are not allowed to move this post out of the trash.' ) ); + wp_die( __( 'Sorry, you are not allowed to restore this item from the Trash.' ) ); if ( !wp_untrash_post( $post_id ) ) - wp_die( __( 'Error in restoring from trash.' ) ); + wp_die( __( 'Error in restoring from Trash.' ) ); } $location = add_query_arg( 'untrashed', count( $post_ids ), $location ); break; @@ -150,7 +156,7 @@ if ( $doaction ) { break; foreach ( (array) $post_ids as $post_id_del ) { if ( !current_user_can( 'delete_post', $post_id_del ) ) - wp_die( __( 'You are not allowed to delete this post.' ) ); + wp_die( __( 'Sorry, you are not allowed to delete this item.' ) ); if ( !wp_delete_attachment( $post_id_del ) ) wp_die( __( 'Error in deleting.' ) ); @@ -180,7 +186,7 @@ get_current_screen()->add_help_tab( array( 'title' => __('Overview'), 'content' => '' . __( 'All the files you’ve uploaded are listed in the Media Library, with the most recent uploads listed first. You can use the Screen Options tab to customize the display of this screen.' ) . '
' . - '' . __( 'You can narrow the list by file type/status using the text link filters at the top of the screen. You also can refine the list by date using the dropdown menu above the media table.' ) . '
' . + '' . __( 'You can narrow the list by file type/status or by date using the dropdown menus above the media table.' ) . '
' . '' . __( 'You can view your media in a simple visual grid or a list with columns. Switch between these views using the icons to the left above the media.' ) . '
' ) ); get_current_screen()->add_help_tab( array( @@ -193,7 +199,7 @@ get_current_screen()->add_help_tab( array( 'id' => 'attaching-files', 'title' => __('Attaching Files'), 'content' => - '' . __( 'If a media file has not been attached to any post, you will see that in the Attached To column, and can click on Attach File to launch a small popup that will allow you to search for a post and attach the file.' ) . '
' + '' . __( 'If a media file has not been attached to any content, you will see that in the Uploaded To column, and can click on Attach to launch a small popup that will allow you to search for existing content and attach the file.' ) . '
' ) ); get_current_screen()->set_help_sidebar( @@ -202,42 +208,64 @@ get_current_screen()->set_help_sidebar( '' . __( 'Support Forums' ) . '
' ); +get_current_screen()->set_screen_reader_content( array( + 'heading_views' => __( 'Filter media items list' ), + 'heading_pagination' => __( 'Media items list navigation' ), + 'heading_list' => __( 'Media items list' ), +) ); + require_once( ABSPATH . 'wp-admin/admin-header.php' ); ?>