mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-08-11 12:20:22 +00:00
First pass at switching to radio inputs for the install screen language selector. Needs some more work. See #28577. Props jorbin
git-svn-id: https://develop.svn.wordpress.org/trunk@28983 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -203,14 +203,19 @@ switch($step) {
|
||||
$body = wp_get_available_translations();
|
||||
if ( $body ) {
|
||||
display_header( 'language-chooser' );
|
||||
|
||||
echo '<form id="setup" method="post" action="install.php?step=1">';
|
||||
echo '<select name="language" id="language-chooser" size="15">';
|
||||
echo '<option selected="selected" value="">English (United States)</option>';
|
||||
echo "<fieldset>\n";
|
||||
echo "<legend class='screen-reader-text'>Select a default language</legend>\n";
|
||||
echo '<input type="radio" checked="checked" class="screen-reader-input" name="language" id="language_default" value="">';
|
||||
echo '<label for="language_default">English (United States)</label>';
|
||||
echo "\n";
|
||||
|
||||
foreach ( $body['languages'] as $language ) {
|
||||
echo '<option value="' . esc_attr( $language['language'] ) . '">' . esc_html( $language['native_name'] ) . "</option>\n";
|
||||
echo '<input type="radio" name="language" class="' . esc_attr( $language['language'] ) . ' screen-reader-input" id="language_'. esc_attr( $language['language'] ) .'" value="' . esc_attr( $language['language'] ) . '">';
|
||||
echo '<label for="language_' . esc_attr( $language['language'] ) . '">' . esc_html( $language['native_name'] ) . "</label>\n";
|
||||
}
|
||||
echo "</select>\n";
|
||||
|
||||
echo "</fieldset>\n";
|
||||
echo '<p class="step"><input type="submit" class="button button-primary button-hero" value="»" /></p>';
|
||||
echo '</form>';
|
||||
break;
|
||||
@@ -334,7 +339,7 @@ switch($step) {
|
||||
}
|
||||
if ( !wp_is_mobile() ) {
|
||||
?>
|
||||
<script type="text/javascript">var t = document.getElementById('weblog_title') || document.getElementById('language-chooser'); if (t){ t.focus(); }</script>
|
||||
<script type="text/javascript">var t = document.getElementById('weblog_title'); if (t){ t.focus(); }</script>
|
||||
<?php } ?>
|
||||
<?php wp_print_scripts( 'user-profile' ); ?>
|
||||
</body>
|
||||
|
||||
Reference in New Issue
Block a user