Make WordPress Core

Ticket #51039: 51039.diff

File 51039.diff, 1.2 KB (added by garrett-eclipse, 5 years ago)

Initial concept introducing the message when not en_US.

  • src/wp-admin/options-general.php

     
    191191                                        sprintf( __( 'The %1$s constant in your %2$s file is no longer needed.' ), 'WPLANG', 'wp-config.php' )
    192192                                );
    193193                        }
    194                         ?>
     194
     195                        if ( '' !== $locale ) : ?>
     196                                <div id="translation-prompt" class="notice notice-info inline">
     197                                        <p>
     198                                                <?php
     199                                                printf(
     200                                                        /* translators: 1: The native name for the locale. 2: The WordPress translation website URL. 3: Accessibility text. */
     201                                                        __( '<strong>Translate WordPress to %1$s:</strong> It looks like you understand %1$s. Did you know you can help translate WordPress and its plugins/themes in your language? <a href="%2$s" target="_blank">Visit this page <span class="screen-reader-text">%3$s</span></a> to get started.' ),
     202                                                        $translations[$locale]['native_name'],
     203                                                        'https://translate.wordpress.org',
     204                                                        /* translators: Accessibility text. */
     205                                                        __( '(opens in a new tab)' )
     206                                                );
     207                                                ?>
     208                                        </p>
     209                                </div>
     210                        <?php endif; ?>
    195211                </td>
    196212        </tr>
    197213        <?php