diff --git a/src/wp-admin/includes/theme.php b/src/wp-admin/includes/theme.php index c3318af8c9..e469f5c14c 100644 --- a/src/wp-admin/includes/theme.php +++ b/src/wp-admin/includes/theme.php @@ -166,17 +166,35 @@ function get_theme_update_available( $theme ) { if ( !is_multisite() ) { if ( ! current_user_can('update_themes') ) { - /* translators: 1: theme name, 2: theme details URL, 3: theme version number */ - $html = sprintf( '
' . __( 'There is a new version of %1$s available. View version %3$s details.' ) . '
', - $theme_name, esc_url( $details_url ), $update['new_version'] ); + /* translators: 1: theme name, 2: theme details URL, 3: accessibility text, 4: version number */ + $html = sprintf( '' . __( 'There is a new version of %1$s available. View version %4$s details.' ) . '
', + $theme_name, + esc_url( $details_url ), + /* translators: 1: theme name, 2: version number */ + esc_attr( sprintf( __( 'View %1$s version %2$s details' ), $theme_name, $update['new_version'] ) ), + $update['new_version'] + ); } elseif ( empty( $update['package'] ) ) { - /* translators: 1: theme name, 2: theme details URL, 3: theme version number */ - $html = sprintf( '' . __( 'There is a new version of %1$s available. View version %3$s details. Automatic update is unavailable for this theme.' ) . '
', - $theme_name, esc_url( $details_url ), $update['new_version'] ); + /* translators: 1: theme name, 2: theme details URL, 3: accessibility text, 4: version number */ + $html = sprintf( '' . __( 'There is a new version of %1$s available. View version %4$s details. Automatic update is unavailable for this theme.' ) . '
', + $theme_name, + esc_url( $details_url ), + /* translators: 1: theme name, 2: version number */ + esc_attr( sprintf( __( 'View %1$s version %2$s details' ), $theme_name, $update['new_version'] ) ), + $update['new_version'] + ); } else { - /* translators: 1: theme name, 2: theme details URL, 3: theme version number, 4: theme update URL */ - $html = sprintf( '' . __( 'There is a new version of %1$s available. View version %3$s details or update now.' ) . '
', - $theme_name, esc_url( $details_url ), $update['new_version'], $update_url ); + /* translators: 1: theme name, 2: theme details URL, 3: accessibility text, 4: version number, 5: update URL, 6: accessibility text */ + $html = sprintf( '' . __( 'There is a new version of %1$s available. View version %4$s details or update now.' ) . '
', + $theme_name, + esc_url( $details_url ), + /* translators: 1: theme name, 2: version number */ + esc_attr( sprintf( __( 'View %1$s version %2$s details' ), $theme_name, $update['new_version'] ) ), + $update['new_version'], + $update_url, + /* translators: %s: theme name */ + esc_attr( sprintf( __( 'Update %s now' ), $theme_name ) ) + ); } } }