Make WordPress Core


Ignore:
Timestamp:
05/04/2008 10:37:06 AM (18 years ago)
Author:
westi
Message:

Associate lables with form fields. Fixes #6859 props MarcoZ.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/edit-link-form.php

    r7737 r7883  
    7575<div id="post-body">
    7676<div id="namediv" class="stuffbox">
    77 <h3><?php _e('Name') ?></h3>
     77<h3><label for="link_name"><?php _e('Name') ?></label></h3>
    7878<div class="inside">
    7979        <input type="text" name="link_name" size="30" tabindex="1" value="<?php echo $link->link_name; ?>" id="link_name" /><br />
    … …  
    8383
    8484<div id="addressdiv" class="stuffbox">
    85 <h3><?php _e('Web Address') ?></h3>
     85<h3><label for="link_url"><?php _e('Web Address') ?></label></h3>
    8686<div class="inside">
    8787        <input type="text" name="link_url" size="30" tabindex="1" value="<?php echo $link->link_url; ?>" id="link_url" /><br />
    … …  
    9191
    9292<div id="descriptiondiv" class="stuffbox">
    93 <h3><?php _e('Description') ?></h3>
     93<h3><label for="link_description"><?php _e('Description') ?></label></h3>
    9494<div class="inside">
    9595        <input type="text" name="link_description" size="30" tabindex="1" value="<?php echo $link->link_description; ?>" id="link_description" /><br />
    … …  
    105105        <h4><a id="category-add-toggle" href="#category-add"><?php _e( '+ Add New Category' ); ?></a></h4>
    106106        <p id="link-category-add" class="wp-hidden-child">
     107                <label class="hidden" for="newcat"><?php _e( '+ Add New Category' ); ?></label>
    107108                <input type="text" name="newcat" id="newcat" class="form-required form-input-tip" value="<?php _e( 'New category name' ); ?>" />
    108109                <input type="button" id="category-add-sumbit" class="add:categorychecklist:linkcategorydiv button" value="<?php _e( 'Add' ); ?>" />
    … …  
    139140<h3><?php _e('Target') ?></h3>
    140141<div class="inside">
     142<fieldset><legend class="hidden"><?php _e('Target') ?></legend>
    141143<label for="link_target_blank" class="selectit">
    142144<input id="link_target_blank" type="radio" name="link_target" value="_blank" <?php echo(($link->link_target == '_blank') ? 'checked="checked"' : ''); ?> />
    … …  
    148150<input id="link_target_none" type="radio" name="link_target" value="" <?php echo(($link->link_target == '') ? 'checked="checked"' : ''); ?> />
    149151<?php _e('none') ?></label>
     152</fieldset>
    150153<p><?php _e('Choose the frame your link targets. Essentially this means if you choose <code>_blank</code> your link will open in a new window.'); ?></p>
    151154</div>
    … …  
    157160<table class="editform" style="width: 100%;" cellspacing="2" cellpadding="5">
    158161        <tr>
    159                 <th style="width: 20%;" scope="row"><?php _e('rel:') ?></th>
     162                <th style="width: 20%;" scope="row"><label for="link_rel"><?php _e('rel:') ?></label></th>
    160163                <td style="width: 80%;"><input type="text" name="link_rel" id="link_rel" size="50" value="<?php echo $link->link_rel; ?>" /></td>
    161164        </tr>
    … …  
    165168                                <tr>
    166169                                        <th scope="row"> <?php _e('identity') ?> </th>
    167                                         <td>
     170                                        <td><fieldset><legend class="hidden"> <?php _e('identity') ?> </legend>
    168171                                                <label for="me">
    169172                                                <input type="checkbox" name="identity" value="me" id="me" <?php xfn_check('identity', 'me'); ?> />
    170173                                                <?php _e('another web address of mine') ?></label>
    171                                         </td>
     174                                        </fieldset></td>
    172175                                </tr>
    173176                                <tr>
    174177                                        <th scope="row"> <?php _e('friendship') ?> </th>
    175                                         <td>
     178                                        <td><fieldset><legend class="hidden"> <?php _e('friendship') ?> </legend>
    176179                                                <label for="contact">
    177180                                                <input class="valinp" type="radio" name="friendship" value="contact" id="contact" <?php xfn_check('friendship', 'contact', 'radio'); ?> /> <?php _e('contact') ?></label>
    … …  
    182185                                                <label for="friendship">
    183186                                                <input name="friendship" type="radio" class="valinp" value="" id="friendship" <?php xfn_check('friendship', '', 'radio'); ?> /> <?php _e('none') ?></label>
    184                                         </td>
     187                                        </fieldset></td>
    185188                                </tr>
    186189                                <tr>
    187190                                        <th scope="row"> <?php _e('physical') ?> </th>
    188                                         <td>
     191                                        <td><fieldset><legend class="hidden"> <?php _e('physical') ?> </legend>
    189192                                                <label for="met">
    190193                                                <input class="valinp" type="checkbox" name="physical" value="met" id="met" <?php xfn_check('physical', 'met'); ?> />
    191194                                                <?php _e('met') ?></label>
    192                                         </td>
     195                                        </fieldset></td>
    193196                                </tr>
    194197                                <tr>
    195198                                        <th scope="row"> <?php _e('professional') ?> </th>
    196                                         <td>
     199                                        <td><fieldset><legend class="hidden"> <?php _e('professional') ?> </legend>
    197200                                                <label for="co-worker">
    198201                                                <input class="valinp" type="checkbox" name="professional" value="co-worker" id="co-worker" <?php xfn_check('professional', 'co-worker'); ?> />
    … …  
    201204                                                <input class="valinp" type="checkbox" name="professional" value="colleague" id="colleague" <?php xfn_check('professional', 'colleague'); ?> />
    202205                                                <?php _e('colleague') ?></label>
    203                                         </td>
     206                                        </fieldset></td>
    204207                                </tr>
    205208                                <tr>
    206209                                        <th scope="row"> <?php _e('geographical') ?> </th>
    207                                         <td>
     210                                        <td><fieldset><legend class="hidden"> <?php _e('geographical') ?> </legend>
    208211                                                <label for="co-resident">
    209212                                                <input class="valinp" type="radio" name="geographical" value="co-resident" id="co-resident" <?php xfn_check('geographical', 'co-resident', 'radio'); ?> />
    … …  
    215218                                                <input class="valinp" type="radio" name="geographical" value="" id="geographical" <?php xfn_check('geographical', '', 'radio'); ?> />
    216219                                                <?php _e('none') ?></label>
    217                                         </td>
     220                                        </fieldset></td>
    218221                                </tr>
    219222                                <tr>
    220223                                        <th scope="row"> <?php _e('family') ?> </th>
    221                                         <td>
     224                                        <td><fieldset><legend class="hidden"> <?php _e('family') ?> </legend>
    222225                                                <label for="child">
    223226                                                <input class="valinp" type="radio" name="family" value="child" id="child" <?php xfn_check('family', 'child', 'radio'); ?>  />
    … …  
    238241                                                <input class="valinp" type="radio" name="family" value="" id="family" <?php xfn_check('family', '', 'radio'); ?> />
    239242                                                <?php _e('none') ?></label>
    240                                         </td>
     243                                        </fieldset></td>
    241244                                </tr>
    242245                                <tr>
    243246                                        <th scope="row"> <?php _e('romantic') ?> </th>
    244                                         <td>
     247                                        <td><fieldset><legend class="hidden"> <?php _e('romantic') ?> </legend>
    245248                                                <label for="muse">
    246249                                                <input class="valinp" type="checkbox" name="romantic" value="muse" id="muse" <?php xfn_check('romantic', 'muse'); ?> />
    … …  
    255258                                                <input class="valinp" type="checkbox" name="romantic" value="sweetheart" id="romantic" <?php xfn_check('romantic', 'sweetheart'); ?> />
    256259                                                <?php _e('sweetheart') ?></label>
    257                                         </td>
     260                                        </fieldset></td>
    258261                                </tr>
    259262                        </table>
Note: See TracChangeset for help on using the changeset viewer.