Make WordPress Core

Changeset 60805


Ignore:
Timestamp:
09/28/2025 10:36:30 PM (7 weeks ago)
Author:
joedolson
Message:

I18n: Combine duplicate text strings into variables.

In cases where a string is used both for a visible label and a screen reader text label, the screen reader text should never be different from the visible label. To help ensure this doesn't happen, use only a single string. The associated screen reader text comments are no longer required.

This is also true for a few cases where there are strings in contexts where variables can't be used. In these cases, the screen reader text comments are also removed.

Props sabernhardt, swissspidy, audrasjb, joedolson.
Fixes #63620.

Location:
trunk/src/wp-admin
Files:
12 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-admin/includes/class-custom-background.php

    r59813 r60805  
    378378
    379379            <?php
     380            $background_position_title = __( 'Image Position' );
     381
    380382            $background_position = sprintf(
    381383                '%s %s',
     
    430432            ?>
    431433<tr>
    432 <th scope="row"><?php _e( 'Image Position' ); ?></th>
    433 <td><fieldset><legend class="screen-reader-text"><span>
    434             <?php
    435             /* translators: Hidden accessibility text. */
    436             _e( 'Image Position' );
    437             ?>
    438 </span></legend>
     434<th scope="row"><?php echo $background_position_title; ?></th>
     435<td><fieldset><legend class="screen-reader-text"><span><?php echo $background_position_title; ?></span></legend>
    439436<div class="background-position-control">
    440437            <?php foreach ( $background_position_options as $group ) : ?>
     
    453450</tr>
    454451
    455 <tr>
    456 <th scope="row"><label for="background-size"><?php _e( 'Image Size' ); ?></label></th>
    457 <td><fieldset><legend class="screen-reader-text"><span>
    458             <?php
    459             /* translators: Hidden accessibility text. */
    460             _e( 'Image Size' );
    461             ?>
    462 </span></legend>
     452            <?php $image_size_title = __( 'Image Size' ); ?>
     453<tr>
     454<th scope="row"><label for="background-size"><?php echo $image_size_title; ?></label></th>
     455<td><fieldset><legend class="screen-reader-text"><span><?php echo $image_size_title; ?></span></legend>
    463456<select id="background-size" name="background-size">
    464457<option value="auto"<?php selected( 'auto', get_theme_mod( 'background_size', get_theme_support( 'custom-background', 'default-size' ) ) ); ?>><?php _ex( 'Original', 'Original Size' ); ?></option>
     
    469462</tr>
    470463
    471 <tr>
    472 <th scope="row"><?php _ex( 'Repeat', 'Background Repeat' ); ?></th>
    473 <td><fieldset><legend class="screen-reader-text"><span>
    474             <?php
    475             /* translators: Hidden accessibility text. */
    476             _ex( 'Repeat', 'Background Repeat' );
    477             ?>
    478 </span></legend>
     464            <?php $background_repeat_title = _x( 'Repeat', 'Background Repeat' ); ?>
     465<tr>
     466<th scope="row"><?php echo $background_repeat_title; ?></th>
     467<td><fieldset><legend class="screen-reader-text"><span><?php echo $background_repeat_title; ?></span></legend>
    479468<input name="background-repeat" type="hidden" value="no-repeat">
    480469<label><input type="checkbox" name="background-repeat" value="repeat"<?php checked( 'repeat', get_theme_mod( 'background_repeat', get_theme_support( 'custom-background', 'default-repeat' ) ) ); ?>> <?php _e( 'Repeat Background Image' ); ?></label>
     
    482471</tr>
    483472
    484 <tr>
    485 <th scope="row"><?php _ex( 'Scroll', 'Background Scroll' ); ?></th>
    486 <td><fieldset><legend class="screen-reader-text"><span>
    487             <?php
    488             /* translators: Hidden accessibility text. */
    489             _ex( 'Scroll', 'Background Scroll' );
    490             ?>
    491 </span></legend>
     473            <?php $background_scroll_title = _x( 'Scroll', 'Background Scroll' ); ?>
     474<tr>
     475<th scope="row"><?php echo $background_scroll_title; ?></th>
     476<td><fieldset><legend class="screen-reader-text"><span><?php echo $background_scroll_title; ?></span></legend>
    492477<input name="background-attachment" type="hidden" value="fixed">
    493478<label><input name="background-attachment" type="checkbox" value="scroll" <?php checked( 'scroll', get_theme_mod( 'background_attachment', get_theme_support( 'custom-background', 'default-attachment' ) ) ); ?>> <?php _e( 'Scroll with Page' ); ?></label>
     
    495480</tr>
    496481<?php endif; // get_background_image() ?>
    497 <tr>
    498 <th scope="row"><?php _e( 'Background Color' ); ?></th>
    499 <td><fieldset><legend class="screen-reader-text"><span>
    500         <?php
    501         /* translators: Hidden accessibility text. */
    502         _e( 'Background Color' );
    503         ?>
    504 </span></legend>
     482
     483        <?php $background_color_title = __( 'Background Color' ); ?>
     484<tr>
     485<th scope="row"><?php echo $background_color_title; ?></th>
     486<td><fieldset><legend class="screen-reader-text"><span><?php echo $background_color_title; ?></span></legend>
    505487        <?php
    506488        $default_color = '';
  • trunk/src/wp-admin/includes/meta-boxes.php

    r59784 r60805  
    12291229
    12301230    ?>
    1231 <fieldset><legend class="screen-reader-text"><span>
    1232     <?php
    1233     /* translators: Hidden accessibility text. */
    1234     _e( 'Target' );
    1235     ?>
    1236 </span></legend>
     1231<fieldset><legend class="screen-reader-text"><span><?php _e( 'Target' ); ?></span></legend>
    12371232<p><label for="link_target_blank" class="selectit">
    12381233<input id="link_target_blank" type="radio" name="link_target" value="_blank" <?php echo ( isset( $link->link_target ) && ( '_blank' === $link->link_target ) ? 'checked="checked"' : '' ); ?> />
     
    13221317        <td><input type="text" name="link_rel" id="link_rel" value="<?php echo ( isset( $link->link_rel ) ? esc_attr( $link->link_rel ) : '' ); ?>" /></td>
    13231318    </tr>
     1319    <?php $identity_group_title = /* translators: xfn: https://gmpg.org/xfn/ */ __( 'identity' ); ?>
    13241320    <tr>
    1325         <th scope="row"><?php /* translators: xfn: https://gmpg.org/xfn/ */ _e( 'identity' ); ?></th>
     1321        <th scope="row"><?php echo $identity_group_title; ?></th>
    13261322        <td><fieldset>
    1327             <legend class="screen-reader-text"><span>
    1328                 <?php
    1329                 /* translators: Hidden accessibility text. xfn: https://gmpg.org/xfn/ */
    1330                 _e( 'identity' );
    1331                 ?>
    1332             </span></legend>
     1323            <legend class="screen-reader-text"><span><?php echo $identity_group_title; ?></span></legend>
    13331324            <label for="me">
    13341325            <input type="checkbox" name="identity" value="me" id="me" <?php xfn_check( 'identity', 'me' ); ?> />
     
    13361327        </fieldset></td>
    13371328    </tr>
     1329    <?php $friendship_group_title = /* translators: xfn: https://gmpg.org/xfn/ */ __( 'friendship' ); ?>
    13381330    <tr>
    1339         <th scope="row"><?php /* translators: xfn: https://gmpg.org/xfn/ */ _e( 'friendship' ); ?></th>
     1331        <th scope="row"><?php echo $friendship_group_title; ?></th>
    13401332        <td><fieldset>
    1341             <legend class="screen-reader-text"><span>
    1342                 <?php
    1343                 /* translators: Hidden accessibility text. xfn: https://gmpg.org/xfn/ */
    1344                 _e( 'friendship' );
    1345                 ?>
    1346             </span></legend>
     1333            <legend class="screen-reader-text"><span><?php echo $friendship_group_title; ?></span></legend>
    13471334            <label for="contact">
    13481335            <input class="valinp" type="radio" name="friendship" value="contact" id="contact" <?php xfn_check( 'friendship', 'contact' ); ?> />&nbsp;<?php /* translators: xfn: https://gmpg.org/xfn/ */ _e( 'contact' ); ?>
     
    13591346        </fieldset></td>
    13601347    </tr>
     1348    <?php $physical_group_title = /* translators: xfn: https://gmpg.org/xfn/ */ __( 'physical' ); ?>
    13611349    <tr>
    1362         <th scope="row"> <?php /* translators: xfn: https://gmpg.org/xfn/ */ _e( 'physical' ); ?> </th>
     1350        <th scope="row"> <?php echo $physical_group_title; ?> </th>
    13631351        <td><fieldset>
    1364             <legend class="screen-reader-text"><span>
    1365                 <?php
    1366                 /* translators: Hidden accessibility text. xfn: https://gmpg.org/xfn/ */
    1367                 _e( 'physical' );
    1368                 ?>
    1369             </span></legend>
     1352            <legend class="screen-reader-text"><span><?php echo $physical_group_title; ?></span></legend>
    13701353            <label for="met">
    13711354            <input class="valinp" type="checkbox" name="physical" value="met" id="met" <?php xfn_check( 'physical', 'met' ); ?> />&nbsp;<?php /* translators: xfn: https://gmpg.org/xfn/ */ _e( 'met' ); ?>
     
    13731356        </fieldset></td>
    13741357    </tr>
     1358    <?php $professional_group_title = /* translators: xfn: https://gmpg.org/xfn/ */ __( 'professional' ); ?>
    13751359    <tr>
    1376         <th scope="row"> <?php /* translators: xfn: https://gmpg.org/xfn/ */ _e( 'professional' ); ?> </th>
     1360        <th scope="row"> <?php echo $professional_group_title; ?> </th>
    13771361        <td><fieldset>
    1378             <legend class="screen-reader-text"><span>
    1379                 <?php
    1380                 /* translators: Hidden accessibility text. xfn: https://gmpg.org/xfn/ */
    1381                 _e( 'professional' );
    1382                 ?>
    1383             </span></legend>
     1362            <legend class="screen-reader-text"><span><?php echo $professional_group_title; ?></span></legend>
    13841363            <label for="co-worker">
    13851364            <input class="valinp" type="checkbox" name="professional" value="co-worker" id="co-worker" <?php xfn_check( 'professional', 'co-worker' ); ?> />&nbsp;<?php /* translators: xfn: https://gmpg.org/xfn/ */ _e( 'co-worker' ); ?>
     
    13901369        </fieldset></td>
    13911370    </tr>
     1371    <?php $geographical_group_title = /* translators: xfn: https://gmpg.org/xfn/ */ __( 'geographical' ); ?>
    13921372    <tr>
    1393         <th scope="row"><?php /* translators: xfn: https://gmpg.org/xfn/ */ _e( 'geographical' ); ?></th>
     1373        <th scope="row"><?php echo $geographical_group_title; ?></th>
    13941374        <td><fieldset>
    1395             <legend class="screen-reader-text"><span>
    1396                 <?php
    1397                 /* translators: Hidden accessibility text. xfn: https://gmpg.org/xfn/ */
    1398                 _e( 'geographical' );
    1399                 ?>
    1400             </span></legend>
     1375            <legend class="screen-reader-text"><span><?php echo $geographical_group_title; ?></span></legend>
    14011376            <label for="co-resident">
    14021377            <input class="valinp" type="radio" name="geographical" value="co-resident" id="co-resident" <?php xfn_check( 'geographical', 'co-resident' ); ?> />&nbsp;<?php /* translators: xfn: https://gmpg.org/xfn/ */ _e( 'co-resident' ); ?>
     
    14101385        </fieldset></td>
    14111386    </tr>
     1387    <?php $family_group_title = /* translators: xfn: https://gmpg.org/xfn/ */ __( 'family' ); ?>
    14121388    <tr>
    1413         <th scope="row"><?php /* translators: xfn: https://gmpg.org/xfn/ */ _e( 'family' ); ?></th>
     1389        <th scope="row"><?php echo $family_group_title; ?></th>
    14141390        <td><fieldset>
    1415             <legend class="screen-reader-text"><span>
    1416                 <?php
    1417                 /* translators: Hidden accessibility text. xfn: https://gmpg.org/xfn/ */
    1418                 _e( 'family' );
    1419                 ?>
    1420             </span></legend>
     1391            <legend class="screen-reader-text"><span><?php echo $family_group_title; ?></span></legend>
    14211392            <label for="child">
    14221393            <input class="valinp" type="radio" name="family" value="child" id="child" <?php xfn_check( 'family', 'child' ); ?> />&nbsp;<?php /* translators: xfn: https://gmpg.org/xfn/ */ _e( 'child' ); ?>
     
    14391410        </fieldset></td>
    14401411    </tr>
     1412    <?php $romantic_group_title = /* translators: xfn: https://gmpg.org/xfn/ */ __( 'romantic' ); ?>
    14411413    <tr>
    1442         <th scope="row"><?php /* translators: xfn: https://gmpg.org/xfn/ */ _e( 'romantic' ); ?></th>
     1414        <th scope="row"><?php echo $romantic_group_title; ?></th>
    14431415        <td><fieldset>
    1444             <legend class="screen-reader-text"><span>
    1445                 <?php
    1446                 /* translators: Hidden accessibility text. xfn: https://gmpg.org/xfn/ */
    1447                 _e( 'romantic' );
    1448                 ?>
    1449             </span></legend>
     1416            <legend class="screen-reader-text"><span><?php echo $romantic_group_title; ?></span></legend>
    14501417            <label for="muse">
    14511418            <input class="valinp" type="checkbox" name="romantic" value="muse" id="muse" <?php xfn_check( 'romantic', 'muse' ); ?> />&nbsp;<?php /* translators: xfn: https://gmpg.org/xfn/ */ _e( 'muse' ); ?>
  • trunk/src/wp-admin/includes/misc.php

    r60681 r60805  
    10231023    ?>
    10241024    <fieldset id="color-picker" class="scheme-list">
    1025         <legend class="screen-reader-text"><span>
    1026             <?php
    1027             /* translators: Hidden accessibility text. */
    1028             _e( 'Administration Color Scheme' );
    1029             ?>
    1030         </span></legend>
     1025        <legend class="screen-reader-text"><span><?php _e( 'Administration Color Scheme' ); ?></span></legend>
    10311026        <?php
    10321027        wp_nonce_field( 'save-color-scheme', 'color-nonce', false );
  • trunk/src/wp-admin/install.php

    r60363 r60805  
    181181            <p id="admin-email-desc"><?php _e( 'Double-check your email address before continuing.' ); ?></p></td>
    182182        </tr>
     183        <?php $blog_privacy_selector_title = has_action( 'blog_privacy_selector' ) ? __( 'Site visibility' ) : __( 'Search engine visibility' ); ?>
    183184        <tr>
    184             <th scope="row"><?php has_action( 'blog_privacy_selector' ) ? _e( 'Site visibility' ) : _e( 'Search engine visibility' ); ?></th>
     185            <th scope="row"><?php echo $blog_privacy_selector_title; ?></th>
    185186            <td>
    186187                <fieldset>
    187                     <legend class="screen-reader-text"><span>
    188                         <?php
    189                         has_action( 'blog_privacy_selector' )
    190                             /* translators: Hidden accessibility text. */
    191                             ? _e( 'Site visibility' )
    192                             /* translators: Hidden accessibility text. */
    193                             : _e( 'Search engine visibility' );
    194                         ?>
    195                     </span></legend>
     188                    <legend class="screen-reader-text"><span><?php echo $blog_privacy_selector_title; ?></span></legend>
    196189                    <?php
    197190                    if ( has_action( 'blog_privacy_selector' ) ) {
  • trunk/src/wp-admin/network/settings.php

    r59784 r60805  
    200200        <h2><?php _e( 'Registration Settings' ); ?></h2>
    201201        <table class="form-table" role="presentation">
    202             <tr>
    203                 <th scope="row"><?php _e( 'Allow new registrations' ); ?></th>
     202            <?php $new_registrations_settings_title = __( 'Allow new registrations' ); ?>
     203            <tr>
     204                <th scope="row"><?php echo $new_registrations_settings_title; ?></th>
    204205                <?php
    205206                if ( ! get_site_option( 'registration' ) ) {
     
    210211                <td>
    211212                    <fieldset>
    212                     <legend class="screen-reader-text">
    213                         <?php
    214                         /* translators: Hidden accessibility text. */
    215                         _e( 'New registrations settings' );
    216                         ?>
    217                     </legend>
     213                    <legend class="screen-reader-text"><?php echo $new_registrations_settings_title; ?></legend>
    218214                    <label><input name="registration" type="radio" id="registration1" value="none"<?php checked( $reg, 'none' ); ?> /> <?php _e( 'Registration is disabled' ); ?></label><br />
    219215                    <label><input name="registration" type="radio" id="registration2" value="user"<?php checked( $reg, 'user' ); ?> /> <?php _e( 'User accounts may be registered' ); ?></label><br />
     
    511507            <h2><?php _e( 'Menu Settings' ); ?></h2>
    512508            <table id="menu" class="form-table">
     509                <?php $enable_administration_menus_title = __( 'Enable administration menus' ); ?>
    513510                <tr>
    514                     <th scope="row"><?php _e( 'Enable administration menus' ); ?></th>
     511                    <th scope="row"><?php echo $enable_administration_menus_title; ?></th>
    515512                    <td>
    516513                        <?php
    517                         echo '<fieldset><legend class="screen-reader-text">' .
    518                             /* translators: Hidden accessibility text. */
    519                             __( 'Enable menus' ) .
    520                         '</legend>';
     514                        echo '<fieldset><legend class="screen-reader-text">' . $enable_administration_menus_title . '</legend>';
    521515
    522516                        foreach ( (array) $menu_items as $key => $val ) {
  • trunk/src/wp-admin/network/site-info.php

    r60358 r60805  
    197197        </tr>
    198198        <?php
     199        $site_attributes_title = __( 'Attributes' );
     200
    199201        $attribute_fields = array( 'public' => _x( 'Public', 'site' ) );
    200202        if ( ! $is_main_site ) {
     
    206208        ?>
    207209        <tr>
    208             <th scope="row"><?php _e( 'Attributes' ); ?></th>
     210            <th scope="row"><?php echo $site_attributes_title; ?></th>
    209211            <td>
    210212            <fieldset>
    211             <legend class="screen-reader-text">
    212                 <?php
    213                 /* translators: Hidden accessibility text. */
    214                 _e( 'Set site attributes' );
    215                 ?>
    216             </legend>
     213            <legend class="screen-reader-text"><?php echo $site_attributes_title; ?></legend>
    217214            <?php foreach ( $attribute_fields as $field_key => $field_label ) : ?>
    218215                <label><input type="checkbox" name="blog[<?php echo $field_key; ?>]" value="1" <?php checked( (bool) $details->$field_key, true ); ?> <?php disabled( ! in_array( (int) $details->$field_key, array( 0, 1 ), true ) ); ?> />
  • trunk/src/wp-admin/options-discussion.php

    r60269 r60805  
    4444
    4545<table class="form-table indent-children" role="presentation">
    46 <tr>
    47 <th scope="row"><?php _e( 'Default post settings' ); ?></th>
    48 <td><fieldset><legend class="screen-reader-text"><span>
    49     <?php
    50     /* translators: Hidden accessibility text. */
    51     _e( 'Default post settings' );
    52     ?>
    53 </span></legend>
     46<?php $default_post_settings_title = __( 'Default post settings' ); ?>
     47<tr>
     48<th scope="row"><?php echo $default_post_settings_title; ?></th>
     49<td><fieldset><legend class="screen-reader-text"><span><?php echo $default_post_settings_title; ?></span></legend>
    5450<label for="default_pingback_flag">
    5551<input name="default_pingback_flag" type="checkbox" id="default_pingback_flag" value="1" <?php checked( '1', get_option( 'default_pingback_flag' ) ); ?> />
     
    6763</fieldset></td>
    6864</tr>
    69 <tr>
    70 <th scope="row"><?php _e( 'Other comment settings' ); ?></th>
    71 <td><fieldset><legend class="screen-reader-text"><span>
    72     <?php
    73     /* translators: Hidden accessibility text. */
    74     _e( 'Other comment settings' );
    75     ?>
    76 </span></legend>
     65<?php $other_comment_settings_title = __( 'Other comment settings' ); ?>
     66<tr>
     67<th scope="row"><?php echo $other_comment_settings_title; ?></th>
     68<td><fieldset><legend class="screen-reader-text"><span><?php echo $other_comment_settings_title; ?></span></legend>
    7769<label for="require_name_email"><input type="checkbox" name="require_name_email" id="require_name_email" value="1" <?php checked( '1', get_option( 'require_name_email' ) ); ?> /> <?php _e( 'Comment author must fill out name and email' ); ?></label>
    7870<br />
     
    130122</tr>
    131123
    132 <tr>
    133 <th scope="row"><?php _e( 'Comment Pagination' ); ?></th>
    134 <td><fieldset><legend class="screen-reader-text"><span>
    135     <?php
    136     /* translators: Hidden accessibility text. */
    137     _e( 'Comment Pagination' );
    138     ?>
    139 </span></legend>
     124<?php $comment_pagination_title = __( 'Comment Pagination' ); ?>
     125<tr>
     126<th scope="row"><?php echo $comment_pagination_title; ?></th>
     127<td><fieldset><legend class="screen-reader-text"><span><?php echo $comment_pagination_title; ?></span></legend>
    140128<input name="page_comments" type="checkbox" id="page_comments" value="1" <?php checked( '1', get_option( 'page_comments' ) ); ?> />
    141129<label for="page_comments"><?php _e( 'Break comments into pages' ); ?></label>
     
    162150</fieldset></td>
    163151</tr>
    164 <tr>
    165 <th scope="row"><?php _e( 'Email me whenever' ); ?></th>
    166 <td><fieldset><legend class="screen-reader-text"><span>
    167     <?php
    168     /* translators: Hidden accessibility text. */
    169     _e( 'Email me whenever' );
    170     ?>
    171 </span></legend>
     152<?php $email_me_whenever_title = __( 'Email me whenever' ); ?>
     153<tr>
     154<th scope="row"><?php echo $email_me_whenever_title; ?></th>
     155<td><fieldset><legend class="screen-reader-text"><span><?php echo $email_me_whenever_title; ?></span></legend>
    172156<label for="comments_notify">
    173157<input name="comments_notify" type="checkbox" id="comments_notify" value="1" <?php checked( '1', get_option( 'comments_notify' ) ); ?> />
     
    179163</fieldset></td>
    180164</tr>
    181 <tr>
    182 <th scope="row"><?php _e( 'Before a comment appears' ); ?></th>
    183 <td><fieldset><legend class="screen-reader-text"><span>
    184     <?php
    185     /* translators: Hidden accessibility text. */
    186     _e( 'Before a comment appears' );
    187     ?>
    188 </span></legend>
     165<?php $before_comment_appears_title = __( 'Before a comment appears' ); ?>
     166<tr>
     167<th scope="row"><?php echo $before_comment_appears_title; ?></th>
     168<td><fieldset><legend class="screen-reader-text"><span><?php echo $before_comment_appears_title; ?></span></legend>
    189169<label for="comment_moderation">
    190170<input name="comment_moderation" type="checkbox" id="comment_moderation" value="1" <?php checked( '1', get_option( 'comment_moderation' ) ); ?> />
     
    194174</fieldset></td>
    195175</tr>
    196 <tr>
    197 <th scope="row"><?php _e( 'Comment Moderation' ); ?></th>
    198 <td><fieldset><legend class="screen-reader-text"><span>
    199     <?php
    200     /* translators: Hidden accessibility text. */
    201     _e( 'Comment Moderation' );
    202     ?>
    203 </span></legend>
     176<?php $comment_moderation_title = __( 'Comment Moderation' ); ?>
     177<tr>
     178<th scope="row"><?php echo $comment_moderation_title; ?></th>
     179<td><fieldset><legend class="screen-reader-text"><span><?php echo $comment_moderation_title; ?></span></legend>
    204180<p><label for="comment_max_links">
    205181<?php
     
    218194</fieldset></td>
    219195</tr>
    220 <tr>
    221 <th scope="row"><?php _e( 'Disallowed Comment Keys' ); ?></th>
    222 <td><fieldset><legend class="screen-reader-text"><span>
    223     <?php
    224     /* translators: Hidden accessibility text. */
    225     _e( 'Disallowed Comment Keys' );
    226     ?>
    227 </span></legend>
     196<?php $disallowed_comment_keys_title = __( 'Disallowed Comment Keys' ); ?>
     197<tr>
     198<th scope="row"><?php echo $disallowed_comment_keys_title; ?></th>
     199<td><fieldset><legend class="screen-reader-text"><span><?php echo $disallowed_comment_keys_title; ?></span></legend>
    228200<p><label for="disallowed_keys"><?php _e( 'When a comment contains any of these words in its content, author name, URL, email, IP address, or browser&#8217;s user agent string, it will be put in the Trash. One word or IP address per line. It will match inside words, so &#8220;press&#8221; will match &#8220;WordPress&#8221;.' ); ?></label></p>
    229201<p>
     
    259231</td>
    260232</tr>
     233<?php $maximum_rating_title = __( 'Maximum Rating' ); ?>
    261234<tr class="avatar-settings<?php echo $show_avatars_class; ?>">
    262 <th scope="row"><?php _e( 'Maximum Rating' ); ?></th>
    263 <td><fieldset><legend class="screen-reader-text"><span>
    264     <?php
    265     /* translators: Hidden accessibility text. */
    266     _e( 'Maximum Rating' );
    267     ?>
    268 </span></legend>
     235<th scope="row"><?php echo $maximum_rating_title; ?></th>
     236<td><fieldset><legend class="screen-reader-text"><span><?php echo $maximum_rating_title; ?></span></legend>
    269237
    270238<?php
     
    287255</fieldset></td>
    288256</tr>
     257<?php $default_avatar_title = __( 'Default Avatar' ); ?>
    289258<tr class="avatar-settings<?php echo $show_avatars_class; ?>">
    290 <th scope="row"><?php _e( 'Default Avatar' ); ?></th>
    291 <td class="defaultavatarpicker"><fieldset><legend class="screen-reader-text"><span>
    292     <?php
    293     /* translators: Hidden accessibility text. */
    294     _e( 'Default Avatar' );
    295     ?>
    296 </span></legend>
     259<th scope="row"><?php echo $default_avatar_title; ?></th>
     260<td class="defaultavatarpicker"><fieldset><legend class="screen-reader-text"><span><?php echo $default_avatar_title; ?></span></legend>
    297261
    298262<p>
  • trunk/src/wp-admin/options-general.php

    r60645 r60805  
    290290</tr>
    291291
    292 <?php if ( ! is_multisite() ) { ?>
    293 
    294 <tr>
    295 <th scope="row"><?php _e( 'Membership' ); ?></th>
    296 <td> <fieldset><legend class="screen-reader-text"><span>
    297     <?php
    298     /* translators: Hidden accessibility text. */
    299     _e( 'Membership' );
    300     ?>
    301 </span></legend><label for="users_can_register">
     292<?php
     293if ( ! is_multisite() ) {
     294    $membership_title = __( 'Membership' );
     295    ?>
     296<tr>
     297<th scope="row"><?php echo $membership_title; ?></th>
     298<td><fieldset><legend class="screen-reader-text"><span><?php echo $membership_title; ?></span></legend><label for="users_can_register">
    302299<input name="users_can_register" type="checkbox" id="users_can_register" value="1" <?php checked( '1', get_option( 'users_can_register' ) ); ?> />
    303300    <?php _e( 'Anyone can register' ); ?></label>
     
    460457<?php endif; ?>
    461458</td>
    462 
    463 </tr>
    464 <tr>
    465 <th scope="row"><?php _e( 'Date Format' ); ?></th>
     459</tr>
     460
     461<?php $date_format_title = __( 'Date Format' ); ?>
     462<tr>
     463<th scope="row"><?php echo $date_format_title; ?></th>
    466464<td>
    467     <fieldset><legend class="screen-reader-text"><span>
    468         <?php
    469         /* translators: Hidden accessibility text. */
    470         _e( 'Date Format' );
    471         ?>
    472     </span></legend>
     465    <fieldset><legend class="screen-reader-text"><span><?php echo $date_format_title; ?></span></legend>
    473466<?php
    474467    /**
     
    512505</td>
    513506</tr>
    514 <tr>
    515 <th scope="row"><?php _e( 'Time Format' ); ?></th>
     507
     508<?php $time_format_title = __( 'Time Format' ); ?>
     509<tr>
     510<th scope="row"><?php echo $time_format_title; ?></th>
    516511<td>
    517     <fieldset><legend class="screen-reader-text"><span>
    518         <?php
    519         /* translators: Hidden accessibility text. */
    520         _e( 'Time Format' );
    521         ?>
    522     </span></legend>
     512    <fieldset><legend class="screen-reader-text"><span><?php echo $time_format_title; ?></span></legend>
    523513<?php
    524514    /**
  • trunk/src/wp-admin/options-media.php

    r59600 r60805  
    5757
    5858<table class="form-table" role="presentation">
     59<?php $thumbnail_size_title = __( 'Thumbnail size' ); ?>
    5960<tr>
    60 <th scope="row"><?php _e( 'Thumbnail size' ); ?></th>
    61 <td><fieldset><legend class="screen-reader-text"><span>
    62     <?php
    63     /* translators: Hidden accessibility text. */
    64     _e( 'Thumbnail size' );
    65     ?>
    66 </span></legend>
     61<th scope="row"><?php echo $thumbnail_size_title; ?></th>
     62<td><fieldset><legend class="screen-reader-text"><span><?php echo $thumbnail_size_title; ?></span></legend>
    6763<label for="thumbnail_size_w"><?php _e( 'Width' ); ?></label>
    6864<input name="thumbnail_size_w" type="number" step="1" min="0" id="thumbnail_size_w" value="<?php form_option( 'thumbnail_size_w' ); ?>" class="small-text" />
     
    7672</tr>
    7773
     74<?php $medium_size_title = __( 'Medium size' ); ?>
    7875<tr>
    79 <th scope="row"><?php _e( 'Medium size' ); ?></th>
    80 <td><fieldset><legend class="screen-reader-text"><span>
    81     <?php
    82     /* translators: Hidden accessibility text. */
    83     _e( 'Medium size' );
    84     ?>
    85 </span></legend>
     76<th scope="row"><?php echo $medium_size_title; ?></th>
     77<td><fieldset><legend class="screen-reader-text"><span><?php echo $medium_size_title; ?></span></legend>
    8678<label for="medium_size_w"><?php _e( 'Max Width' ); ?></label>
    8779<input name="medium_size_w" type="number" step="1" min="0" id="medium_size_w" value="<?php form_option( 'medium_size_w' ); ?>" class="small-text" />
     
    9284</tr>
    9385
     86<?php $large_size_title = __( 'Large size' ); ?>
    9487<tr>
    95 <th scope="row"><?php _e( 'Large size' ); ?></th>
    96 <td><fieldset><legend class="screen-reader-text"><span>
    97     <?php
    98     /* translators: Hidden accessibility text. */
    99     _e( 'Large size' );
    100     ?>
    101 </span></legend>
     88<th scope="row"><?php echo $large_size_title; ?></th>
     89<td><fieldset><legend class="screen-reader-text"><span><?php echo $large_size_title; ?></span></legend>
    10290<label for="large_size_w"><?php _e( 'Max Width' ); ?></label>
    10391<input name="large_size_w" type="number" step="1" min="0" id="large_size_w" value="<?php form_option( 'large_size_w' ); ?>" class="small-text" />
  • trunk/src/wp-admin/options-permalink.php

    r57793 r60805  
    327327<table class="form-table permalink-structure" role="presentation">
    328328<tbody>
     329<?php $permalink_structure_title = __( 'Permalink structure' ); ?>
    329330<tr>
    330     <th scope="row"><?php _e( 'Permalink structure' ); ?></th>
     331    <th scope="row"><?php echo $permalink_structure_title; ?></th>
    331332    <td>
    332333        <fieldset class="structure-selection">
    333             <legend class="screen-reader-text">
    334                 <?php
    335                 /* translators: Hidden accessibility text. */
    336                 _e( 'Permalink structure' );
    337                 ?>
    338             </legend>
     334            <legend class="screen-reader-text"><?php echo $permalink_structure_title; ?></legend>
    339335            <?php foreach ( $default_structures as $input ) : ?>
    340336            <div class="row">
  • trunk/src/wp-admin/options-reading.php

    r58147 r60805  
    8282        update_option( 'show_on_front', 'posts' );
    8383    }
     84
     85    $your_homepage_displays_title = __( 'Your homepage displays' );
    8486    ?>
    8587<table class="form-table" role="presentation">
    8688<tr>
    87 <th scope="row"><?php _e( 'Your homepage displays' ); ?></th>
     89<th scope="row"><?php echo $your_homepage_displays_title; ?></th>
    8890<td id="front-static-pages"><fieldset>
    89     <legend class="screen-reader-text"><span>
    90         <?php
    91         /* translators: Hidden accessibility text. */
    92         _e( 'Your homepage displays' );
    93         ?>
    94     </span></legend>
     91    <legend class="screen-reader-text"><span><?php echo $your_homepage_displays_title; ?></span></legend>
    9592    <p><label>
    9693        <input name="show_on_front" type="radio" value="posts" class="tog" <?php checked( 'posts', get_option( 'show_on_front' ) ); ?> />
     
    180177<td><input name="posts_per_rss" type="number" step="1" min="1" id="posts_per_rss" value="<?php form_option( 'posts_per_rss' ); ?>" class="small-text" /> <?php _e( 'items' ); ?></td>
    181178</tr>
    182 <tr>
    183 <th scope="row"><?php _e( 'For each post in a feed, include' ); ?> </th>
     179
     180<?php $rss_use_excerpt_title = __( 'For each post in a feed, include' ); ?>
     181<tr>
     182<th scope="row"><?php echo $rss_use_excerpt_title; ?> </th>
    184183<td><fieldset>
    185     <legend class="screen-reader-text"><span>
    186         <?php
    187         /* translators: Hidden accessibility text. */
    188         _e( 'For each post in a feed, include' );
    189         ?>
    190     </span></legend>
     184    <legend class="screen-reader-text"><span><?php echo $rss_use_excerpt_title; ?></span></legend>
    191185    <p>
    192186        <label><input name="rss_use_excerpt" type="radio" value="0" <?php checked( 0, get_option( 'rss_use_excerpt' ) ); ?> /> <?php _e( 'Full text' ); ?></label><br />
     
    205199</tr>
    206200
     201<?php $blog_privacy_selector_title = has_action( 'blog_privacy_selector' ) ? __( 'Site visibility' ) : __( 'Search engine visibility' ); ?>
    207202<tr class="option-site-visibility">
    208 <th scope="row"><?php has_action( 'blog_privacy_selector' ) ? _e( 'Site visibility' ) : _e( 'Search engine visibility' ); ?> </th>
     203<th scope="row"><?php echo $blog_privacy_selector_title; ?> </th>
    209204<td><fieldset>
    210     <legend class="screen-reader-text"><span>
    211         <?php
    212         has_action( 'blog_privacy_selector' )
    213             /* translators: Hidden accessibility text. */
    214             ? _e( 'Site visibility' )
    215             /* translators: Hidden accessibility text. */
    216             : _e( 'Search engine visibility' );
    217         ?>
    218     </span></legend>
     205    <legend class="screen-reader-text"><span><?php echo $blog_privacy_selector_title; ?></span></legend>
    219206<?php if ( has_action( 'blog_privacy_selector' ) ) : ?>
    220207    <input id="blog-public" type="radio" name="blog_public" value="1" <?php checked( '1', get_option( 'blog_public' ) ); ?> />
  • trunk/src/wp-admin/options-writing.php

    r57793 r60805  
    6868<table class="form-table" role="presentation">
    6969<?php if ( get_site_option( 'initial_db_version' ) < 32453 ) : ?>
    70 <tr>
    71 <th scope="row"><?php _e( 'Formatting' ); ?></th>
    72 <td><fieldset><legend class="screen-reader-text"><span>
    73     <?php
    74     /* translators: Hidden accessibility text. */
    75     _e( 'Formatting' );
    76     ?>
    77 </span></legend>
     70    <?php $formatting_title = __( 'Formatting' ); ?>
     71<tr>
     72<th scope="row"><?php echo $formatting_title; ?></th>
     73<td><fieldset><legend class="screen-reader-text"><span><?php echo $formatting_title; ?></span></legend>
    7874<label for="use_smilies">
    7975<input name="use_smilies" type="checkbox" id="use_smilies" value="1" <?php checked( '1', get_option( 'use_smilies' ) ); ?> />
Note: See TracChangeset for help on using the changeset viewer.