Change update string to indicate if version is the original English one, or the local one. Props nbachiyski. fixes #10117 for trunk
git-svn-id: https://develop.svn.wordpress.org/trunk@11669 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
a228b4a413
commit
dac10ca31b
@ -14,7 +14,7 @@ if ( ! current_user_can('update_plugins') )
|
|||||||
|
|
||||||
function list_core_update( $update ) {
|
function list_core_update( $update ) {
|
||||||
global $wp_local_package;
|
global $wp_local_package;
|
||||||
$version_string = 'en_US' == $update->locale ?
|
$version_string = ('en_US' == $update->locale && 'en_US' == get_locale() ) ?
|
||||||
$update->current : sprintf("%s–<strong>%s</strong>", $update->current, $update->locale);
|
$update->current : sprintf("%s–<strong>%s</strong>", $update->current, $update->locale);
|
||||||
$current = false;
|
$current = false;
|
||||||
if ( !isset($update->response) || 'latest' == $update->response )
|
if ( !isset($update->response) || 'latest' == $update->response )
|
||||||
@ -53,6 +53,9 @@ function list_core_update( $update ) {
|
|||||||
echo '</p>';
|
echo '</p>';
|
||||||
if ( 'en_US' != $update->locale && ( !isset($wp_local_package) || $wp_local_package != $update->locale ) )
|
if ( 'en_US' != $update->locale && ( !isset($wp_local_package) || $wp_local_package != $update->locale ) )
|
||||||
echo '<p class="hint">'.__('This localized version contains both the translation and various other localization fixes. You can skip upgrading if you want to keep your current translation.').'</p>';
|
echo '<p class="hint">'.__('This localized version contains both the translation and various other localization fixes. You can skip upgrading if you want to keep your current translation.').'</p>';
|
||||||
|
else if ( 'en_US' == $update->locale && get_locale() != 'en_US' ) {
|
||||||
|
echo '<p class="hint">'.sprintf( __('You are about to install WordPress %s <strong>in English.</strong> There is a chance this upgrade will break your translation. You may prefer to wait for the localized version to be released.'), $update->current ).'</p>';
|
||||||
|
}
|
||||||
echo '</form>';
|
echo '</form>';
|
||||||
|
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user