Ticket #26879: 26879-14.diff
File 26879-14.diff, 11.9 KB (added by , 9 years ago) |
---|
-
src/wp-admin/css/install.css
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 } -
src/wp-admin/setup-config.php
142 142 } 143 143 ?> 144 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> 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 <p><?php _e( "Once you fill in this information, WordPress will create a configuration file called <code>wp-config.php</code>. This connects WordPress with your database, where your content and settings will be stored. Need more help? Check out our <a href='https://codex.wordpress.org/Editing_wp-config.php'>documentation</a>." ); ?></p> 154 <p><?php _e( "If you’re all ready…" ); ?></p> 153 155 <p><?php 154 156 /* translators: %s: wp-config.php */ 155 157 printf( __( 'We’re going to use this information to create a %s file.' ), … … 171 173 ?></p> 172 174 <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 175 174 <p class="step"><a href=" <?php echo $step_1; ?>" class="button button-large"><?php _e( 'Let’s go!' ); ?></a></p>176 <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 177 <?php 176 178 break; 177 179 … … 244 246 $install .= '?language=en_US'; 245 247 } 246 248 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>';249 $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>'; 248 250 249 if ( empty( $prefix ) ) 250 wp_die( __( '<strong>ERROR</strong>: "Table Prefix" must not be empty.' . $tryagain_link ) ); 251 // Validate $prefix: it must not be empty 252 if ( empty( $prefix ) ) { 253 $die .= '<p style="text-align: center;">' . __( "Oops, the Table Prefix field can't be empty. Please go back and try again." ) . '</p>'; 254 $die .= '<p style="text-align: center;">' . __( "Need more help? Check out our <a href='https://codex.wordpress.org/Editing_wp-config.php#table_prefix'>documentation</a>." ) . '</p>'; 255 $die .= ( __( $tryagain_link ) ); 256 wp_die( $die ); 257 } 251 258 252 259 // 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 ) ); 260 if ( preg_match( '|[^a-z0-9_]|i', $prefix ) ) { 261 $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>'; 262 $die .= '<p style="text-align: center;">' . __( "Need more help? Check out our <a href='https://codex.wordpress.org/Editing_wp-config.php#table_prefix'>documentation</a>." ) . '</p>'; 263 $die .= ( __( $tryagain_link ) ); 264 wp_die( $die ); 265 } 255 266 256 267 // Test the db connection. 257 268 /**#@+ … … 343 354 ?></p> 344 355 <p><?php 345 356 /* 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>' );357 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 358 ?></p> 348 359 <textarea id="wp-config" cols="98" rows="15" class="code" readonly="readonly"><?php 349 360 foreach ( $config_file as $line ) { -
src/wp-includes/functions.php
2615 2615 $message = "<ul>\n\t\t<li>" . join( "</li>\n\t\t<li>", $errors ) . "</li>\n\t</ul>"; 2616 2616 break; 2617 2617 } 2618 } elseif ( is_string( $message ) ) {2618 } elseif ( is_string( $message ) && empty( $r['raw'] ) ) { 2619 2619 $message = "<p>$message</p>"; 2620 2620 } 2621 2621 … … 2639 2639 $text_direction = 'rtl'; 2640 2640 elseif ( function_exists( 'is_rtl' ) && is_rtl() ) 2641 2641 $text_direction = 'rtl'; 2642 2643 $site_url = wp_guess_url(); 2644 2645 $classes = 'wp-core-ui'; 2646 if ( ! empty( $r['error'] ) ) { 2647 $classes .= ' error-page'; 2648 } 2649 if ( 'rtl' === $text_direction ) { 2650 $classes .= ' rtl'; 2651 } 2642 2652 ?> 2643 2653 <!DOCTYPE html> 2644 2654 <!-- 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 … … 2648 2658 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> 2649 2659 <meta name="viewport" content="width=device-width"> 2650 2660 <title><?php echo $title ?></title> 2651 <style type="text/css"> 2652 html { 2653 background: #f1f1f1; 2654 } 2655 body { 2656 background: #fff; 2657 color: #444; 2658 font-family: "Open Sans", sans-serif; 2659 margin: 2em auto; 2660 padding: 1em 2em; 2661 max-width: 700px; 2662 -webkit-box-shadow: 0 1px 3px rgba(0,0,0,0.13); 2663 box-shadow: 0 1px 3px rgba(0,0,0,0.13); 2664 } 2665 h1 { 2666 border-bottom: 1px solid #dadada; 2667 clear: both; 2668 color: #666; 2669 font: 24px "Open Sans", sans-serif; 2670 margin: 30px 0 0 0; 2671 padding: 0; 2672 padding-bottom: 7px; 2673 } 2674 #error-page { 2675 margin-top: 50px; 2676 } 2677 #error-page p { 2678 font-size: 14px; 2679 line-height: 1.5; 2680 margin: 25px 0 20px; 2681 } 2682 #error-page code { 2683 font-family: Consolas, Monaco, monospace; 2684 } 2685 ul li { 2686 margin-bottom: 10px; 2687 font-size: 14px ; 2688 } 2689 a { 2690 color: #0073aa; 2691 } 2692 a:hover, 2693 a:active { 2694 color: #00a0d2; 2695 } 2696 a:focus { 2697 color: #124964; 2698 -webkit-box-shadow: 2699 0 0 0 1px #5b9dd9, 2700 0 0 2px 1px rgba(30, 140, 190, .8); 2701 box-shadow: 2702 0 0 0 1px #5b9dd9, 2703 0 0 2px 1px rgba(30, 140, 190, .8); 2704 outline: none; 2705 } 2706 .button { 2707 background: #f7f7f7; 2708 border: 1px solid #ccc; 2709 color: #555; 2710 display: inline-block; 2711 text-decoration: none; 2712 font-size: 13px; 2713 line-height: 26px; 2714 height: 28px; 2715 margin: 0; 2716 padding: 0 10px 1px; 2717 cursor: pointer; 2718 -webkit-border-radius: 3px; 2719 -webkit-appearance: none; 2720 border-radius: 3px; 2721 white-space: nowrap; 2722 -webkit-box-sizing: border-box; 2723 -moz-box-sizing: border-box; 2724 box-sizing: border-box; 2725 2726 -webkit-box-shadow: 0 1px 0 #ccc; 2727 box-shadow: 0 1px 0 #ccc; 2728 vertical-align: top; 2729 } 2730 2731 .button.button-large { 2732 height: 30px; 2733 line-height: 28px; 2734 padding: 0 12px 2px; 2735 } 2736 2737 .button:hover, 2738 .button:focus { 2739 background: #fafafa; 2740 border-color: #999; 2741 color: #23282d; 2742 } 2743 2744 .button:focus { 2745 border-color: #5b9dd9; 2746 -webkit-box-shadow: 0 0 3px rgba( 0, 115, 170, .8 ); 2747 box-shadow: 0 0 3px rgba( 0, 115, 170, .8 ); 2748 outline: none; 2749 } 2750 2751 .button:active { 2752 background: #eee; 2753 border-color: #999; 2754 -webkit-box-shadow: inset 0 2px 5px -3px rgba( 0, 0, 0, 0.5 ); 2755 box-shadow: inset 0 2px 5px -3px rgba( 0, 0, 0, 0.5 ); 2756 -webkit-transform: translateY(1px); 2757 -ms-transform: translateY(1px); 2758 transform: translateY(1px); 2759 } 2760 2761 <?php 2762 if ( 'rtl' == $text_direction ) { 2763 echo 'body { font-family: Tahoma, Arial; }'; 2764 } 2765 ?> 2766 </style> 2661 <link rel="stylesheet" type="text/css" href="<?php echo $site_url; ?>/wp-admin/css/install.css" /> 2662 <link rel="stylesheet" type="text/css" href="<?php echo $site_url; ?>/wp-includes/css/buttons.css" /> 2767 2663 </head> 2768 <body id="error-page">2664 <body class="<?php echo $classes; ?>"> 2769 2665 <?php endif; // ! did_action( 'admin_head' ) ?> 2770 2666 <?php echo $message; ?> 2771 2667 </body> -
src/wp-load.php
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">%1$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">%1$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 }