Make WordPress Core

Ticket #29452: 29452.2.diff

File 29452.2.diff, 3.8 KB (added by johnbillion, 12 years ago)
  • src/wp-admin/setup-config.php

     
    6565 * @since 2.3.0
    6666 */
    6767function setup_config_display_header( $body_classes = array() ) {
    68         global $wp_version;
     68        global $wp_version, $wp_locale;
    6969        $body_classes = (array) $body_classes;
    7070        $body_classes[] = 'wp-core-ui';
    7171        if ( is_rtl() ) {
     
    8787<body class="<?php echo implode( ' ', $body_classes ); ?>">
    8888<h1 id="logo"><a href="<?php esc_attr_e( 'https://wordpress.org/' ); ?>" tabindex="-1"><?php _e( 'WordPress' ); ?></a></h1>
    8989<?php
     90        if ( strpos( $GLOBALS['wp_version'], '-src' ) and ( 'rtl' == _x( 'ltr', 'text direction' ) ) ) {
     91                $wp_locale->rtl_src_admin_notice();
     92        }
    9093} // end function setup_config_display_header();
    9194
    9295$language = '';
     
    110113                        $loaded_language = wp_download_language_pack( $language );
    111114                        if ( $loaded_language ) {
    112115                                load_default_textdomain( $loaded_language );
     116                                $GLOBALS['wp_locale'] = new WP_Locale();
    113117                        }
    114118                }
    115119
    116120                setup_config_display_header();
     121
    117122                $step_1 = 'setup-config.php?step=1';
    118123                if ( isset( $_REQUEST['noapi'] ) ) {
    119124                        $step_1 .= '&amp;noapi';
     
    144149
    145150        case 1:
    146151                load_default_textdomain( $language );
     152                $GLOBALS['wp_locale'] = new WP_Locale();
     153
    147154                setup_config_display_header();
    148155        ?>
    149156<form method="post" action="setup-config.php?step=2">
     
    184191
    185192        case 2:
    186193        load_default_textdomain( $language );
     194        $GLOBALS['wp_locale'] = new WP_Locale();
     195
    187196        $dbname = trim( wp_unslash( $_POST[ 'dbname' ] ) );
    188197        $uname = trim( wp_unslash( $_POST[ 'uname' ] ) );
    189198        $pwd = trim( wp_unslash( $_POST[ 'pwd' ] ) );
  • src/wp-admin/install.php

     
    5454 * @since 2.5.0
    5555 */
    5656function display_header( $body_classes = '' ) {
     57        global $wp_locale;
    5758        header( 'Content-Type: text/html; charset=utf-8' );
    5859        if ( is_rtl() ) {
    5960                $body_classes .= 'rtl';
     
    7677<h1 id="logo"><a href="<?php echo esc_url( __( 'https://wordpress.org/' ) ); ?>" tabindex="-1"><?php _e( 'WordPress' ); ?></a></h1>
    7778
    7879<?php
     80        if ( strpos( $GLOBALS['wp_version'], '-src' ) and ( 'rtl' == _x( 'ltr', 'text direction' ) ) ) {
     81                $wp_locale->rtl_src_admin_notice();
     82        }
     83
    7984} // end display_header()
    8085
    8186/**
     
    204209                        $loaded_language = wp_download_language_pack( $langugage );
    205210                        if ( $loaded_language ) {
    206211                                load_default_textdomain( $loaded_language );
     212                                $GLOBALS['wp_locale'] = new WP_Locale();
    207213                        }
    208214                }
    209215
    210216                display_header();
     217
    211218?>
    212219<h1><?php _ex( 'Welcome', 'Howdy' ); ?></h1>
    213220<p><?php __( 'Welcome to the famous five-minute WordPress installation process! Just fill in the information below and you&#8217;ll be on your way to using the most extendable and powerful personal publishing platform in the world.' ); ?></p>
     
    221228        case 2:
    222229                if ( ! empty( $langugage ) && load_default_textdomain( $langugage ) ) {
    223230                        $loaded_language = $langugage;
     231                        $GLOBALS['wp_locale'] = new WP_Locale();
    224232                } else {
    225233                        $loaded_language = 'en_US';
    226234                }
     
    229237                        wp_die( $wpdb->error->get_error_message() );
    230238
    231239                display_header();
     240
    232241                // Fill in the data we gathered
    233242                $weblog_title = isset( $_POST['weblog_title'] ) ? trim( wp_unslash( $_POST['weblog_title'] ) ) : '';
    234243                $user_name = isset($_POST['user_name']) ? trim( wp_unslash( $_POST['user_name'] ) ) : '';
  • src/wp-admin/css/install.css

     
    230230        border-color: #8dff1c !important;
    231231}
    232232
     233.error p,
    233234.message {
    234235        border: 1px solid #c00;
    235236        padding: 0.5em 0.7em;