mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-08-12 04:40:26 +00:00
Standardize around "Update" instead of "Upgrade." props RanYanivHartstein. props latz. fixes #14107
git-svn-id: https://develop.svn.wordpress.org/trunk@16696 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -205,7 +205,7 @@ class WP_MS_Themes_List_Table extends WP_List_Table {
|
||||
$text = _n( 'Disabled <span class="count">(%s)</span>', 'Disabled <span class="count">(%s)</span>', $count );
|
||||
break;
|
||||
case 'upgrade':
|
||||
$text = _n( 'Upgrade Available <span class="count">(%s)</span>', 'Upgrade Available <span class="count">(%s)</span>', $count );
|
||||
$text = _n( 'Update Available <span class="count">(%s)</span>', 'Update Available <span class="count">(%s)</span>', $count );
|
||||
break;
|
||||
case 'search':
|
||||
$text = _n( 'Search Results <span class="count">(%s)</span>', 'Search Results <span class="count">(%s)</span>', $count );
|
||||
|
||||
@@ -233,7 +233,7 @@ class WP_Plugins_List_Table extends WP_List_Table {
|
||||
$text = _n( 'Drop-ins <span class="count">(%s)</span>', 'Drop-ins <span class="count">(%s)</span>', $count );
|
||||
break;
|
||||
case 'upgrade':
|
||||
$text = _n( 'Upgrade Available <span class="count">(%s)</span>', 'Upgrade Available <span class="count">(%s)</span>', $count );
|
||||
$text = _n( 'Update Available <span class="count">(%s)</span>', 'Update Available <span class="count">(%s)</span>', $count );
|
||||
break;
|
||||
case 'search':
|
||||
$text = _n( 'Search Results <span class="count">(%s)</span>', 'Search Results <span class="count">(%s)</span>', $count );
|
||||
|
||||
@@ -368,14 +368,14 @@ class Plugin_Upgrader extends WP_Upgrader {
|
||||
|
||||
function upgrade_strings() {
|
||||
$this->strings['up_to_date'] = __('The plugin is at the latest version.');
|
||||
$this->strings['no_package'] = __('Upgrade package not available.');
|
||||
$this->strings['no_package'] = __('Update package not available.');
|
||||
$this->strings['downloading_package'] = __('Downloading update from <span class="code">%s</span>…');
|
||||
$this->strings['unpack_package'] = __('Unpacking the update…');
|
||||
$this->strings['deactivate_plugin'] = __('Deactivating the plugin…');
|
||||
$this->strings['remove_old'] = __('Removing the old version of the plugin…');
|
||||
$this->strings['remove_old_failed'] = __('Could not remove the old plugin.');
|
||||
$this->strings['process_failed'] = __('Plugin upgrade failed.');
|
||||
$this->strings['process_success'] = __('Plugin upgraded successfully.');
|
||||
$this->strings['process_failed'] = __('Plugin update failed.');
|
||||
$this->strings['process_success'] = __('Plugin updated successfully.');
|
||||
}
|
||||
|
||||
function install_strings() {
|
||||
@@ -608,13 +608,13 @@ class Theme_Upgrader extends WP_Upgrader {
|
||||
|
||||
function upgrade_strings() {
|
||||
$this->strings['up_to_date'] = __('The theme is at the latest version.');
|
||||
$this->strings['no_package'] = __('Upgrade package not available.');
|
||||
$this->strings['no_package'] = __('Update package not available.');
|
||||
$this->strings['downloading_package'] = __('Downloading update from <span class="code">%s</span>…');
|
||||
$this->strings['unpack_package'] = __('Unpacking the update…');
|
||||
$this->strings['remove_old'] = __('Removing the old version of the theme…');
|
||||
$this->strings['remove_old_failed'] = __('Could not remove the old theme.');
|
||||
$this->strings['process_failed'] = __('Theme upgrade failed.');
|
||||
$this->strings['process_success'] = __('Theme upgraded successfully.');
|
||||
$this->strings['process_failed'] = __('Theme update failed.');
|
||||
$this->strings['process_success'] = __('Theme updated successfully.');
|
||||
}
|
||||
|
||||
function install_strings() {
|
||||
@@ -861,7 +861,7 @@ class Core_Upgrader extends WP_Upgrader {
|
||||
|
||||
function upgrade_strings() {
|
||||
$this->strings['up_to_date'] = __('WordPress is at the latest version.');
|
||||
$this->strings['no_package'] = __('Upgrade package not available.');
|
||||
$this->strings['no_package'] = __('Update package not available.');
|
||||
$this->strings['downloading_package'] = __('Downloading update from <span class="code">%s</span>…');
|
||||
$this->strings['unpack_package'] = __('Unpacking the update…');
|
||||
$this->strings['copy_failed'] = __('Could not copy files.');
|
||||
@@ -1017,7 +1017,7 @@ class Plugin_Upgrader_Skin extends WP_Upgrader_Skin {
|
||||
}
|
||||
|
||||
function __construct($args = array()) {
|
||||
$defaults = array( 'url' => '', 'plugin' => '', 'nonce' => '', 'title' => __('Upgrade Plugin') );
|
||||
$defaults = array( 'url' => '', 'plugin' => '', 'nonce' => '', 'title' => __('Update Plugin') );
|
||||
$args = wp_parse_args($args, $defaults);
|
||||
|
||||
$this->plugin = $args['plugin'];
|
||||
@@ -1388,7 +1388,7 @@ class Theme_Upgrader_Skin extends WP_Upgrader_Skin {
|
||||
}
|
||||
|
||||
function __construct($args = array()) {
|
||||
$defaults = array( 'url' => '', 'theme' => '', 'nonce' => '', 'title' => __('Upgrade Theme') );
|
||||
$defaults = array( 'url' => '', 'theme' => '', 'nonce' => '', 'title' => __('Update Theme') );
|
||||
$args = wp_parse_args($args, $defaults);
|
||||
|
||||
$this->theme = $args['theme'];
|
||||
|
||||
@@ -239,15 +239,15 @@ function theme_update_available( $theme ) {
|
||||
$theme_name = is_object($theme) ? $theme->name : (is_array($theme) ? $theme['Name'] : '');
|
||||
$details_url = add_query_arg(array('TB_iframe' => 'true', 'width' => 1024, 'height' => 800), $update['url']); //Theme browser inside WP? replace this, Also, theme preview JS will override this on the available list.
|
||||
$update_url = wp_nonce_url('update.php?action=upgrade-theme&theme=' . urlencode($stylesheet), 'upgrade-theme_' . $stylesheet);
|
||||
$update_onclick = 'onclick="if ( confirm(\'' . esc_js( __("Upgrading this theme will lose any customizations you have made. 'Cancel' to stop, 'OK' to upgrade.") ) . '\') ) {return true;}return false;"';
|
||||
$update_onclick = 'onclick="if ( confirm(\'' . esc_js( __("Updating this theme will lose any customizations you have made. 'Cancel' to stop, 'OK' to upgrade.") ) . '\') ) {return true;}return false;"';
|
||||
|
||||
if ( !is_multisite() ) {
|
||||
if ( ! current_user_can('update_themes') )
|
||||
printf( '<p><strong>' . __('There is a new version of %1$s available. <a href="%2$s" class="thickbox" title="%1$s">View version %3$s details</a>.') . '</strong></p>', $theme_name, $details_url, $update['new_version']);
|
||||
else if ( empty($update['package']) )
|
||||
printf( '<p><strong>' . __('There is a new version of %1$s available. <a href="%2$s" class="thickbox" title="%1$s">View version %3$s details</a>. <em>Automatic upgrade is unavailable for this theme.</em>') . '</strong></p>', $theme_name, $details_url, $update['new_version']);
|
||||
printf( '<p><strong>' . __('There is a new version of %1$s available. <a href="%2$s" class="thickbox" title="%1$s">View version %3$s details</a>. <em>Automatic update is unavailable for this theme.</em>') . '</strong></p>', $theme_name, $details_url, $update['new_version']);
|
||||
else
|
||||
printf( '<p><strong>' . __('There is a new version of %1$s available. <a href="%2$s" class="thickbox" title="%1$s">View version %3$s details</a> or <a href="%4$s" %5$s>upgrade automatically</a>.') . '</strong></p>', $theme_name, $details_url, $update['new_version'], $update_url, $update_onclick );
|
||||
printf( '<p><strong>' . __('There is a new version of %1$s available. <a href="%2$s" class="thickbox" title="%1$s">View version %3$s details</a> or <a href="%4$s" %5$s>update automatically</a>.') . '</strong></p>', $theme_name, $details_url, $update['new_version'], $update_url, $update_onclick );
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -199,9 +199,9 @@ function wp_plugin_update_row( $file, $plugin_data ) {
|
||||
if ( ! current_user_can('update_plugins') )
|
||||
printf( __('There is a new version of %1$s available. <a href="%2$s" class="thickbox" title="%3$s">View version %4$s details</a>.'), $plugin_name, esc_url($details_url), esc_attr($plugin_name), $r->new_version );
|
||||
else if ( empty($r->package) )
|
||||
printf( __('There is a new version of %1$s available. <a href="%2$s" class="thickbox" title="%3$s">View version %4$s details</a>. <em>Automatic upgrade is unavailable for this plugin.</em>'), $plugin_name, esc_url($details_url), esc_attr($plugin_name), $r->new_version );
|
||||
printf( __('There is a new version of %1$s available. <a href="%2$s" class="thickbox" title="%3$s">View version %4$s details</a>. <em>Automatic update is unavailable for this plugin.</em>'), $plugin_name, esc_url($details_url), esc_attr($plugin_name), $r->new_version );
|
||||
else
|
||||
printf( __('There is a new version of %1$s available. <a href="%2$s" class="thickbox" title="%3$s">View version %4$s details</a> or <a href="%5$s">upgrade automatically</a>.'), $plugin_name, esc_url($details_url), esc_attr($plugin_name), $r->new_version, wp_nonce_url( self_admin_url('update.php?action=upgrade-plugin&plugin=') . $file, 'upgrade-plugin_' . $file) );
|
||||
printf( __('There is a new version of %1$s available. <a href="%2$s" class="thickbox" title="%3$s">View version %4$s details</a> or <a href="%5$s">update automatically</a>.'), $plugin_name, esc_url($details_url), esc_attr($plugin_name), $r->new_version, wp_nonce_url( self_admin_url('update.php?action=upgrade-plugin&plugin=') . $file, 'upgrade-plugin_' . $file) );
|
||||
}
|
||||
|
||||
do_action( "in_plugin_update_message-$file", $plugin_data, $r );
|
||||
@@ -274,9 +274,9 @@ function wp_theme_update_row( $theme_key, $theme ) {
|
||||
if ( ! current_user_can('update_themes') )
|
||||
printf( __('There is a new version of %1$s available. <a href="%2$s" class="thickbox" title="%3$s">View version %4$s details</a>.'), $theme['Name'], esc_url($details_url), esc_attr($theme['Name']), $r->new_version );
|
||||
else if ( empty( $r['package'] ) )
|
||||
printf( __('There is a new version of %1$s available. <a href="%2$s" class="thickbox" title="%3$s">View version %4$s details</a>. <em>Automatic upgrade is unavailable for this plugin.</em>'), $theme['Name'], esc_url($details_url), esc_attr($theme['Name']), $r['new_version'] );
|
||||
printf( __('There is a new version of %1$s available. <a href="%2$s" class="thickbox" title="%3$s">View version %4$s details</a>. <em>Automatic update is unavailable for this plugin.</em>'), $theme['Name'], esc_url($details_url), esc_attr($theme['Name']), $r['new_version'] );
|
||||
else
|
||||
printf( __('There is a new version of %1$s available. <a href="%2$s" class="thickbox" title="%3$s">View version %4$s details</a> or <a href="%5$s">upgrade automatically</a>.'), $theme['Name'], esc_url($details_url), esc_attr($theme['Name']), $r['new_version'], wp_nonce_url( self_admin_url('update.php?action=upgrade-theme&theme=') . $theme_key, 'upgrade-theme_' . $theme_key) );
|
||||
printf( __('There is a new version of %1$s available. <a href="%2$s" class="thickbox" title="%3$s">View version %4$s details</a> or <a href="%5$s">update automatically</a>.'), $theme['Name'], esc_url($details_url), esc_attr($theme['Name']), $r['new_version'], wp_nonce_url( self_admin_url('update.php?action=upgrade-theme&theme=') . $theme_key, 'upgrade-theme_' . $theme_key) );
|
||||
|
||||
do_action( "in_theme_update_message-$theme_key", $theme, $r );
|
||||
|
||||
|
||||
@@ -1656,7 +1656,7 @@ function make_site_theme_from_oldschool($theme_name, $template) {
|
||||
}
|
||||
|
||||
// Add a theme header.
|
||||
$header = "/*\nTheme Name: $theme_name\nTheme URI: " . __get_option('siteurl') . "\nDescription: A theme automatically created by the upgrade.\nVersion: 1.0\nAuthor: Moi\n*/\n";
|
||||
$header = "/*\nTheme Name: $theme_name\nTheme URI: " . __get_option('siteurl') . "\nDescription: A theme automatically created by the update.\nVersion: 1.0\nAuthor: Moi\n*/\n";
|
||||
|
||||
$stylelines = file_get_contents("$site_dir/style.css");
|
||||
if ($stylelines) {
|
||||
|
||||
Reference in New Issue
Block a user