Upgrade/Install: Display plugin and theme update counts on WordPress Updates screen.

This restores the information that was previously included in a title attribute tooltip on pending updates link in the toolbar.

Follow-up to [50801].

Props sabernhardt, audrasjb, mukesh27, davidbaumwald.
Fixes #53031.
Built from https://develop.svn.wordpress.org/trunk@50803


git-svn-id: http://core.svn.wordpress.org/trunk@50412 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Sergey Biryukov 2021-05-02 16:54:06 +00:00
parent 85d526c5d0
commit 29cd5d902d
2 changed files with 23 additions and 3 deletions

View File

@ -449,8 +449,18 @@ function list_plugin_updates() {
} else {
$core_update_version = $core_updates[0]->current;
}
$plugins_count = count( $plugins );
?>
<h2><?php _e( 'Plugins' ); ?></h2>
<h2>
<?php
printf(
'%s <span class="count">(%d)</span>',
__( 'Plugins' ),
number_format_i18n( $plugins_count )
);
?>
</h2>
<p><?php _e( 'The following plugins have new versions available. Check the ones you want to update and then click &#8220;Update Plugins&#8221;.' ); ?></p>
<form method="post" action="<?php echo esc_url( $form_action ); ?>" name="upgrade-plugins" class="upgrade">
<?php wp_nonce_field( 'upgrade-core' ); ?>
@ -602,8 +612,18 @@ function list_theme_updates() {
}
$form_action = 'update-core.php?action=do-theme-upgrade';
$themes_count = count( $themes );
?>
<h2><?php _e( 'Themes' ); ?></h2>
<h2>
<?php
printf(
'%s <span class="count">(%d)</span>',
__( 'Themes' ),
number_format_i18n( $themes_count )
);
?>
</h2>
<p><?php _e( 'The following themes have new versions available. Check the ones you want to update and then click &#8220;Update Themes&#8221;.' ); ?></p>
<p>
<?php

View File

@ -13,7 +13,7 @@
*
* @global string $wp_version
*/
$wp_version = '5.8-alpha-50802';
$wp_version = '5.8-alpha-50803';
/**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.