Ticket #26879: 26879-16.diff
File 26879-16.diff, 12.6 KB (added by , 9 years ago) |
---|
-
wp-admin/css/install.css
diff --git a/wp-admin/css/install.css b/wp-admin/css/install.css index c033ea5..86ec9f1 100644
a b submit { 211 211 font-size: 18px; 212 212 } 213 213 214 #error-page {214 body.error-page { 215 215 margin-top: 50px; 216 216 } 217 217 218 #error-page p {218 body.error-page p { 219 219 font-size: 14px; 220 220 line-height: 18px; 221 221 margin: 25px 0 20px; 222 222 } 223 223 224 #error-page code, .code {225 font-family: Consolas, Monaco, monospace;226 }227 228 224 .wp-hide-pw > .dashicons { 229 225 line-height: inherit; 230 226 } -
wp-admin/setup-config.php
diff --git a/wp-admin/setup-config.php b/wp-admin/setup-config.php index fd8d32b..04f060e 100644
a b function setup_config_display_header( $body_classes = array() ) { 141 141 $step_1 .= '&language=' . $loaded_language; 142 142 } 143 143 ?> 144 <h1 class="screen-reader-text"><?php _e( 'Before getting started' ) ?></h1> 145 <p><?php _e( 'Welcome to WordPress. Before getting started, we need some information on the database. You will need to know the following items before proceeding.' ) ?></p> 144 <h1 class="screen-reader-text"><?php _e( 'Before getting started' ); ?></h1> 145 <p><?php _e( "OK! We need some information about your database." ); ?></p> 146 <p><?php _e( "This information is available through your web host. If you don't have it, you'll need to get in touch with them. Here's what you need:" ); ?></p> 146 147 <ol> 147 148 <li><?php _e( 'Database name' ); ?></li> 148 149 <li><?php _e( 'Database username' ); ?></li> 149 150 <li><?php _e( 'Database password' ); ?></li> 150 151 <li><?php _e( 'Database host' ); ?></li> 151 <li><?php _e( 'Table prefix (if you want to run more than one WordPress in a single database)' ); ?></li>152 152 </ol> 153 153 <p><?php 154 /* translators: 1: wp-config.php, 2: Codex URL */ 155 printf( __( "Once you fill in this information, WordPress will create a configuration file called %1$s. This connects WordPress with your database, where your content and settings will be stored. Need more help? Check out our <a href='%2$s'>documentation</a>." ), 156 '<code>wp-config.php</code>', 157 __( 'https://codex.wordpress.org/Editing_wp-config.php' ) 158 ); 159 ?></p> 160 <p><?php _e( "If you’re all ready…" ); ?></p> 161 <p><?php 154 162 /* translators: %s: wp-config.php */ 155 163 printf( __( 'We’re going to use this information to create a %s file.' ), 156 164 '<code>wp-config.php</code>' … … function setup_config_display_header( $body_classes = array() ) { 171 179 ?></p> 172 180 <p><?php _e( 'In all likelihood, these items were supplied to you by your Web Host. If you don’t have this information, then you will need to contact them before you can continue. If you’re all ready…' ); ?></p> 173 181 174 <p class="step"><a href=" <?php echo $step_1; ?>" class="button button-large"><?php _e( 'Let’s go!' ); ?></a></p>182 <p class="step"><a href="setup-config.php?step=1<?php if ( isset( $_GET['noapi'] ) ) echo '&noapi'; ?>" class="button button-large"><?php _e( 'Let’s Go!' ); ?></a></p> 175 183 <?php 176 184 break; 177 185 … … function setup_config_display_header( $body_classes = array() ) { 244 252 $install .= '?language=en_US'; 245 253 } 246 254 247 $tryagain_link = '</p><p class="step"><a href="' . $step_1 . '" onclick="javascript:history.go(-1);return false;" class="button button-large">' . __( 'Try again' ) . '</a>'; 248 249 if ( empty( $prefix ) ) 250 wp_die( __( '<strong>ERROR</strong>: "Table Prefix" must not be empty.' . $tryagain_link ) ); 255 $tryagain_link = '</p><p class="step"><a href="setup-config.php?step=1" onclick="javascript:history.go(-1);return false;" class="button button-large">' . __( 'Try Again' ) . '</a>'; 256 257 // Validate $prefix: it must not be empty 258 if ( empty( $prefix ) ) { 259 $die .= '<p style="text-align: center;">' . __( "Oops, the Table Prefix field can't be empty. Please go back and try again." ) . '</p>'; 260 $die .= '<p style="text-align: center;">' . sprintf( 261 /* translators: %s: Codex URL */ 262 __( "Need more help? Check out our <a href='%s'>documentation</a>." ), 263 __( 'https://codex.wordpress.org/Editing_wp-config.php#table_prefix' ) 264 ) . '</p>'; 265 $die .= ( __( $tryagain_link ) ); 266 wp_die( $die ); 267 } 251 268 252 269 // Validate $prefix: it can only contain letters, numbers and underscores. 253 if ( preg_match( '|[^a-z0-9_]|i', $prefix ) ) 254 wp_die( __( '<strong>ERROR</strong>: "Table Prefix" can only contain numbers, letters, and underscores.' . $tryagain_link ) ); 270 if ( preg_match( '|[^a-z0-9_]|i', $prefix ) ) { 271 $die .= '<p style="text-align: center;">' . __( "Oops, the Table Prefix field can only contain numbers, letters, and underscores. Please go back and try again. ") . '</p>'; 272 $die .= '<p style="text-align: center;">' . sprintf( 273 /* translators: %s: Codex URL */ 274 __( "Need more help? Check out our <a href='%s'>documentation</a>." ), 275 __( 'https://codex.wordpress.org/Editing_wp-config.php#table_prefix' ) 276 ) . '</p>'; 277 $die .= ( __( $tryagain_link ) ); 278 wp_die( $die ); 279 } 255 280 256 281 // Test the db connection. 257 282 /**#@+ … … function setup_config_display_header( $body_classes = array() ) { 343 368 ?></p> 344 369 <p><?php 345 370 /* translators: %s: wp-config.php */ 346 printf( __( ' You can create the %s manually and paste the following text into it.'), '<code>wp-config.php</code>' );371 printf( __( 'To continue, manually create a file named %s in the root directory where the rest of your WordPress files are located and copy and paste the following text into the file:'), '<code>wp-config.php</code>' ); 347 372 ?></p> 348 373 <textarea id="wp-config" cols="98" rows="15" class="code" readonly="readonly"><?php 349 374 foreach ( $config_file as $line ) { -
wp-includes/functions.php
diff --git a/wp-includes/functions.php b/wp-includes/functions.php index bcd56f7..7be8371 100644
a b function _default_wp_die_handler( $message, $title = '', $args = array() ) { 2613 2613 $message = "<ul>\n\t\t<li>" . join( "</li>\n\t\t<li>", $errors ) . "</li>\n\t</ul>"; 2614 2614 break; 2615 2615 } 2616 } elseif ( is_string( $message ) ) {2616 } elseif ( is_string( $message ) && empty( $r['raw'] ) ) { 2617 2617 $message = "<p>$message</p>"; 2618 2618 } 2619 2619 … … function _default_wp_die_handler( $message, $title = '', $args = array() ) { 2637 2637 $text_direction = 'rtl'; 2638 2638 elseif ( function_exists( 'is_rtl' ) && is_rtl() ) 2639 2639 $text_direction = 'rtl'; 2640 2641 $site_url = wp_guess_url(); 2642 2643 $classes = 'wp-core-ui'; 2644 if ( ! empty( $r['error'] ) ) { 2645 $classes .= ' error-page'; 2646 } 2647 if ( 'rtl' === $text_direction ) { 2648 $classes .= ' rtl'; 2649 } 2640 2650 ?> 2641 2651 <!DOCTYPE html> 2642 2652 <!-- Ticket #11289, IE bug fix: always pad the error page with enough characters such that it is greater than 512 bytes, even after gzip compression abcdefghijklmnopqrstuvwxyz1234567890aabbccddeeffgghhiijjkkllmmnnooppqqrrssttuuvvwwxxyyzz11223344556677889900abacbcbdcdcededfefegfgfhghgihihjijikjkjlklkmlmlnmnmononpopoqpqprqrqsrsrtstsubcbcdcdedefefgfabcadefbghicjkldmnoepqrfstugvwxhyz1i234j567k890laabmbccnddeoeffpgghqhiirjjksklltmmnunoovppqwqrrxsstytuuzvvw0wxx1yyz2z113223434455666777889890091abc2def3ghi4jkl5mno6pqr7stu8vwx9yz11aab2bcc3dd4ee5ff6gg7hh8ii9j0jk1kl2lmm3nnoo4p5pq6qrr7ss8tt9uuvv0wwx1x2yyzz13aba4cbcb5dcdc6dedfef8egf9gfh0ghg1ihi2hji3jik4jkj5lkl6kml7mln8mnm9ono … … function _default_wp_die_handler( $message, $title = '', $args = array() ) { 2646 2656 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> 2647 2657 <meta name="viewport" content="width=device-width"> 2648 2658 <title><?php echo $title ?></title> 2649 <style type="text/css"> 2650 html { 2651 background: #f1f1f1; 2652 } 2653 body { 2654 background: #fff; 2655 color: #444; 2656 font-family: "Open Sans", sans-serif; 2657 margin: 2em auto; 2658 padding: 1em 2em; 2659 max-width: 700px; 2660 -webkit-box-shadow: 0 1px 3px rgba(0,0,0,0.13); 2661 box-shadow: 0 1px 3px rgba(0,0,0,0.13); 2662 } 2663 h1 { 2664 border-bottom: 1px solid #dadada; 2665 clear: both; 2666 color: #666; 2667 font: 24px "Open Sans", sans-serif; 2668 margin: 30px 0 0 0; 2669 padding: 0; 2670 padding-bottom: 7px; 2671 } 2672 #error-page { 2673 margin-top: 50px; 2674 } 2675 #error-page p { 2676 font-size: 14px; 2677 line-height: 1.5; 2678 margin: 25px 0 20px; 2679 } 2680 #error-page code { 2681 font-family: Consolas, Monaco, monospace; 2682 } 2683 ul li { 2684 margin-bottom: 10px; 2685 font-size: 14px ; 2686 } 2687 a { 2688 color: #0073aa; 2689 } 2690 a:hover, 2691 a:active { 2692 color: #00a0d2; 2693 } 2694 a:focus { 2695 color: #124964; 2696 -webkit-box-shadow: 2697 0 0 0 1px #5b9dd9, 2698 0 0 2px 1px rgba(30, 140, 190, .8); 2699 box-shadow: 2700 0 0 0 1px #5b9dd9, 2701 0 0 2px 1px rgba(30, 140, 190, .8); 2702 outline: none; 2703 } 2704 .button { 2705 background: #f7f7f7; 2706 border: 1px solid #ccc; 2707 color: #555; 2708 display: inline-block; 2709 text-decoration: none; 2710 font-size: 13px; 2711 line-height: 26px; 2712 height: 28px; 2713 margin: 0; 2714 padding: 0 10px 1px; 2715 cursor: pointer; 2716 -webkit-border-radius: 3px; 2717 -webkit-appearance: none; 2718 border-radius: 3px; 2719 white-space: nowrap; 2720 -webkit-box-sizing: border-box; 2721 -moz-box-sizing: border-box; 2722 box-sizing: border-box; 2723 2724 -webkit-box-shadow: 0 1px 0 #ccc; 2725 box-shadow: 0 1px 0 #ccc; 2726 vertical-align: top; 2727 } 2728 2729 .button.button-large { 2730 height: 30px; 2731 line-height: 28px; 2732 padding: 0 12px 2px; 2733 } 2734 2735 .button:hover, 2736 .button:focus { 2737 background: #fafafa; 2738 border-color: #999; 2739 color: #23282d; 2740 } 2741 2742 .button:focus { 2743 border-color: #5b9dd9; 2744 -webkit-box-shadow: 0 0 3px rgba( 0, 115, 170, .8 ); 2745 box-shadow: 0 0 3px rgba( 0, 115, 170, .8 ); 2746 outline: none; 2747 } 2748 2749 .button:active { 2750 background: #eee; 2751 border-color: #999; 2752 -webkit-box-shadow: inset 0 2px 5px -3px rgba( 0, 0, 0, 0.5 ); 2753 box-shadow: inset 0 2px 5px -3px rgba( 0, 0, 0, 0.5 ); 2754 -webkit-transform: translateY(1px); 2755 -ms-transform: translateY(1px); 2756 transform: translateY(1px); 2757 } 2758 2759 <?php 2760 if ( 'rtl' == $text_direction ) { 2761 echo 'body { font-family: Tahoma, Arial; }'; 2762 } 2763 ?> 2764 </style> 2659 <link rel="stylesheet" type="text/css" href="<?php echo $site_url; ?>/wp-admin/css/install.css" /> 2660 <link rel="stylesheet" type="text/css" href="<?php echo $site_url; ?>/wp-includes/css/buttons.css" /> 2765 2661 </head> 2766 <body id="error-page">2662 <body class="<?php echo $classes; ?>"> 2767 2663 <?php endif; // ! did_action( 'admin_head' ) ?> 2768 2664 <?php echo $message; ?> 2769 2665 </body> -
wp-load.php
diff --git a/wp-load.php b/wp-load.php index 94a8b54..4465898 100644
a b 72 72 wp_load_translations_early(); 73 73 74 74 // Die with an error message 75 $die = sprintf( 75 $die = sprintf( 76 __( '<h1 id="logo"><a href="%s">WordPress</a></h1>' ), 77 /* translators: %s: WordPress url */ 78 __( 'https://wordpress.org/' ) 79 ); 80 $die .= '<h1>' . __( 'Welcome to WordPress' ) . '</h1>'; 81 $die .= '<p>' . __( "In just a few minutes, you'll be all set up with WordPress and ready to create your own corner of the web." ) . '</p>'; 82 $die .= '<p>' . sprintf( 83 /* translators: %s: Codex plugins url, Codex themes url */ 84 __( 'This free and Open Source software is built and maintained by a community of hundreds of volunteers. Transform your website with countless of <a href="%1$s">plugins</a> and <a href="%2$s">themes</a> available from right within WordPress.' ), 85 'https://wordpress.org/plugins/', 86 'https://wordpress.org/themes/' 87 ) . '</p>'; 88 $die .= '<p>' . __( 'Write your blog, build your first website, launch your business, share your photos with your friends. You can do just about anything you can imagine.' ) . '</p>'; 89 $die .= '<p>' . sprintf( 90 __( '<a href="%1$s" class="button button-large">%2$s</a>' ), 91 $path, 92 __( "Let's Get Started!" ) 93 ) . '</p>'; 94 $die .= sprintf( 76 95 /* translators: %s: wp-config.php */ 77 96 __( "There doesn't seem to be a %s file. I need this before we can get started." ), 78 97 '<code>wp-config.php</code>' 79 98 ) . '</p>'; 80 99 $die .= '<p>' . sprintf( 81 100 /* translators: %s: Codex URL */ 82 __( "Need more help? <a href='%s'>We got it</a>." ), 83 __( 'https://codex.wordpress.org/Editing_wp-config.php' ) 101 __( 'Need more help? <a href="%1$s">%2$s</a>.' ), 102 __( 'https://codex.wordpress.org/Editing_wp-config.php' ), 103 __( 'We got it' ) 84 104 ) . '</p>'; 85 105 $die .= '<p>' . sprintf( 86 106 /* translators: %s: wp-config.php */ 87 107 __( "You can create a %s file through a web interface, but this doesn't work for all server setups. The safest way is to manually create the file." ), 88 108 '<code>wp-config.php</code>' 89 109 ) . '</p>'; 90 $die .= '<p><a href="' . $path . '" class="button button-large">' . __( "Create a Configuration File" ) . '</a>'; 110 $die .= '<p>' . sprintf( 111 '<a href="%s" class="button button-large">%s</a>', 112 $path, 113 __( 'Create a Configuration File' ) 114 ) . '</p>'; 91 115 92 wp_die( $die, __( 'W ordPress › Error') );116 wp_die( $die, __( 'Welcome to WordPress!' ), array( 'error' => false, 'raw' => true ) ); 93 117 }