Accessibility: Remove inappropriate content from the Media Library screens headings.

Props joedolson.

See #26601.

Built from https://develop.svn.wordpress.org/trunk@39526


git-svn-id: http://core.svn.wordpress.org/trunk@39466 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Andrea Fercia 2016-12-06 22:18:42 +00:00
parent ab3bca05c8
commit 26ef4bd86d
2 changed files with 12 additions and 8 deletions

View File

@ -73,14 +73,16 @@ if ( 'grid' === $mode ) {
require_once( ABSPATH . 'wp-admin/admin-header.php' );
?>
<div class="wrap" id="wp-media-grid" data-search="<?php _admin_search_query() ?>">
<h1>
<h1 class="wp-heading-inline"><?php echo esc_html( $title ); ?></h1>
<?php
echo esc_html( $title );
if ( current_user_can( 'upload_files' ) ) { ?>
<a href="<?php echo admin_url( 'media-new.php' ); ?>" class="page-title-action"><?php echo esc_html_x( 'Add New', 'file' ); ?></a><?php
}
?>
</h1>
<hr class="wp-header-end">
<div class="error hide-if-js">
<p><?php printf(
/* translators: %s: list view URL */
@ -221,18 +223,20 @@ require_once( ABSPATH . 'wp-admin/admin-header.php' );
?>
<div class="wrap">
<h1>
<h1 class="wp-heading-inline"><?php echo esc_html( $title ); ?></h1>
<?php
echo esc_html( $title );
if ( current_user_can( 'upload_files' ) ) { ?>
<a href="<?php echo admin_url( 'media-new.php' ); ?>" class="page-title-action"><?php echo esc_html_x('Add New', 'file'); ?></a><?php
<a href="<?php echo admin_url( 'media-new.php' ); ?>" class="page-title-action"><?php echo esc_html_x( 'Add New', 'file' ); ?></a><?php
}
if ( isset( $_REQUEST['s'] ) && strlen( $_REQUEST['s'] ) ) {
/* translators: %s: search keywords */
printf( '<span class="subtitle">' . __( 'Search results for &#8220;%s&#8221;' ) . '</span>', get_search_query() );
}
?>
</h1>
<hr class="wp-header-end">
<?php
$message = '';

View File

@ -4,7 +4,7 @@
*
* @global string $wp_version
*/
$wp_version = '4.8-alpha-39522';
$wp_version = '4.8-alpha-39526';
/**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.