]> scripts.mit.edu Git - autoinstalls/wordpress.git/blobdiff - wp-admin/includes/class-wp-upgrader-skins.php
WordPress 4.4
[autoinstalls/wordpress.git] / wp-admin / includes / class-wp-upgrader-skins.php
index 3e9a5556b63d0a4325e85c0d510010f98097c494..77a5e7bdfa331a20ed3c5041dd64026af8a56fc3 100644 (file)
@@ -281,8 +281,11 @@ class Bulk_Upgrader_Skin extends WP_Upgrader_Skin {
         */
        public function add_strings() {
                $this->upgrader->strings['skin_upgrade_start'] = __('The update process is starting. This process may take a while on some hosts, so please be patient.');
-               $this->upgrader->strings['skin_update_failed_error'] = __('An error occurred while updating %1$s: <strong>%2$s</strong>');
+               /* translators: 1: Title of an update, 2: Error message */
+               $this->upgrader->strings['skin_update_failed_error'] = __('An error occurred while updating %1$s: %2$s');
+               /* translators: 1: Title of an update */
                $this->upgrader->strings['skin_update_failed'] = __('The update of %1$s failed.');
+               /* translators: 1: Title of an update */
                $this->upgrader->strings['skin_update_successful'] = __( '%1$s updated successfully.' ) . ' <a onclick="%2$s" href="#" class="hide-if-no-js"><span>' . __( 'Show Details' ) . '</span><span class="hidden">' . __( 'Hide Details' ) . '</span></a>';
                $this->upgrader->strings['skin_upgrade_end'] = __('All updates have been completed.');
        }
@@ -366,7 +369,7 @@ class Bulk_Upgrader_Skin extends WP_Upgrader_Skin {
         */
        public function before($title = '') {
                $this->in_loop = true;
-               printf( '<h4>' . $this->upgrader->strings['skin_before_update_header'] . ' <span class="spinner waiting-' . $this->upgrader->update_current . '"></span></h4>',  $title, $this->upgrader->update_current, $this->upgrader->update_count);
+               printf( '<h2>' . $this->upgrader->strings['skin_before_update_header'] . ' <span class="spinner waiting-' . $this->upgrader->update_current . '"></span></h2>', $title, $this->upgrader->update_current, $this->upgrader->update_count );
                echo '<script type="text/javascript">jQuery(\'.waiting-' . esc_js($this->upgrader->update_current) . '\').css("display", "inline-block");</script>';
                echo '<div class="update-messages hide-if-js" id="progress-' . esc_attr($this->upgrader->update_current) . '"><p>';
                $this->flush_output();
@@ -379,10 +382,11 @@ class Bulk_Upgrader_Skin extends WP_Upgrader_Skin {
        public function after($title = '') {
                echo '</p></div>';
                if ( $this->error || ! $this->result ) {
-                       if ( $this->error )
-                               echo '<div class="error"><p>' . sprintf($this->upgrader->strings['skin_update_failed_error'], $title, $this->error) . '</p></div>';
-                       else
+                       if ( $this->error ) {
+                               echo '<div class="error"><p>' . sprintf($this->upgrader->strings['skin_update_failed_error'], $title, '<strong>' . $this->error . '</strong>' ) . '</p></div>';
+                       } else {
                                echo '<div class="error"><p>' . sprintf($this->upgrader->strings['skin_update_failed'], $title) . '</p></div>';
+                       }
 
                        echo '<script type="text/javascript">jQuery(\'#progress-' . esc_js($this->upgrader->update_current) . '\').show();</script>';
                }
@@ -739,7 +743,7 @@ class Theme_Upgrader_Skin extends WP_Upgrader_Skin {
                                }
                        } elseif ( current_user_can( 'switch_themes' ) ) {
                                if ( current_user_can( 'edit_theme_options' ) && current_user_can( 'customize' ) ) {
-                                       $update_actions['preview'] .= '<a href="' . wp_customize_url( $stylesheet ) . '" class="hide-if-no-customize load-customize"><span aria-hidden="true">' . __( 'Live Preview' ) . '</span><span class="screen-reader-text">' . sprintf( __( 'Live Preview &#8220;%s&#8221;' ), $name ) . '</span></a>';
+                                       $update_actions['preview'] = '<a href="' . wp_customize_url( $stylesheet ) . '" class="hide-if-no-customize load-customize"><span aria-hidden="true">' . __( 'Live Preview' ) . '</span><span class="screen-reader-text">' . sprintf( __( 'Live Preview &#8220;%s&#8221;' ), $name ) . '</span></a>';
                                }
                                $update_actions['activate'] = '<a href="' . esc_url( $activate_link ) . '" class="activatelink"><span aria-hidden="true">' . __( 'Activate' ) . '</span><span class="screen-reader-text">' . sprintf( __( 'Activate &#8220;%s&#8221;' ), $name ) . '</span></a>';
                        }
@@ -801,7 +805,7 @@ class Language_Pack_Upgrader_Skin extends WP_Upgrader_Skin {
 
                echo '<div class="update-messages lp-show-latest">';
 
-               printf( '<h4>' . __( 'Updating translations for %1$s (%2$s)&#8230;' ) . '</h4>', $name, $this->language_update->language );
+               printf( '<h2>' . __( 'Updating translations for %1$s (%2$s)&#8230;' ) . '</h2>', $name, $this->language_update->language );
        }
 
        /**