Ticket #29814: 29814.patch
| File 29814.patch, 1.9 KB (added by , 11 years ago) |
|---|
-
.php
old new $languages = get_available_languages(); 308 308 if ( ! is_multisite() && defined( 'WPLANG' ) && '' !== WPLANG && 'en_US' !== WPLANG && ! in_array( WPLANG, $languages ) ) { 309 309 $languages[] = WPLANG; 310 310 } 311 if ( $languages ) {312 311 ?> 313 312 <tr> 314 313 <th width="33%" scope="row"><label for="WPLANG"><?php _e( 'Site Language' ); ?></label></th> 315 314 <td> 316 315 <?php 317 $locale = get_locale(); 318 if ( ! in_array( $locale, $languages ) ) { 319 $locale = ''; 316 if ( $languages ) { 317 $locale = get_locale(); 318 if ( ! in_array( $locale, $languages ) ) { 319 $locale = ''; 320 } 321 322 wp_dropdown_languages( array( 323 'name' => 'WPLANG', 324 'id' => 'WPLANG', 325 'selected' => $locale, 326 'languages' => $languages, 327 ) ); 328 } else { 329 if ( is_super_admin() ) { 330 ?> 331 <p class="description"> 332 <strong><?php _e( 'Note:' ); ?></strong> 333 <?php 334 printf( '<br/>' ); 335 printf( __( 'This site currently only supports the U.S. English default language.' ) ); 336 printf( '<br/>' ); 337 printf( __( 'More information on multi-language support can be found <a href="%s">here</a>.' ), 'http://codex.wordpress.org/Installing_WordPress_in_Your_Language' ); 338 ?> 339 </p> 340 <?php 341 } 320 342 } 321 343 322 wp_dropdown_languages( array(323 'name' => 'WPLANG',324 'id' => 'WPLANG',325 'selected' => $locale,326 'languages' => $languages,327 ) );328 329 344 // Add note about deprecated WPLANG constant. 330 345 if ( defined( 'WPLANG' ) && ( '' !== WPLANG ) && $locale !== WPLANG ) { 331 346 if ( is_super_admin() ) { … … if ( ! is_multisite() && defined( 'WPLANG' ) && '' 341 356 </td> 342 357 </tr> 343 358 <?php 344 }345 359 ?> 346 360 </table> 347 361