Make WordPress Core

Changeset 7472


Ignore:
Timestamp:
03/22/2008 09:14:49 AM (17 years ago)
Author:
westi
Message:

Improve the tabindex's on the Write>Post page. Need to do the others too.

Location:
trunk
Files:
3 edited

Legend:

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

    r7439 r7472  
    8585<p><strong><?php _e('Publish Status') ?></strong></p>
    8686<p>
    87 <select name='post_status'>
     87<select name='post_status' tabindex='4'>
    8888<?php if ( current_user_can('publish_posts') ) : // Contributors only get "Unpublished" and "Pending Review" ?>
    8989<option<?php selected( $post->post_status, 'publish' ); selected( $post->post_status, 'private' );?> value='publish'><?php _e('Published') ?></option>
     
    9898
    9999<?php if ( current_user_can( 'publish_posts' ) ) : ?>
    100 <p><label for="post_status_private" class="selectit"><input id="post_status_private" name="post_status" type="checkbox" value="private" <?php checked($post->post_status, 'private'); ?> /> <?php _e('Keep this post private') ?></label></p>
     100<p><label for="post_status_private" class="selectit"><input id="post_status_private" name="post_status" type="checkbox" value="private" <?php checked($post->post_status, 'private'); ?> tabindex="4" /> <?php _e('Keep this post private') ?></label></p>
    101101<?php endif; ?>
    102102<?php
     
    121121<?php if ( current_user_can( 'publish_posts' ) ) : // Contributors don't get to choose the date of publish ?>
    122122<p class="curtime"><?php printf($stamp, $date, $time); ?>
    123 &nbsp;<a href="#edit_timestamp" class="edit-timestamp"><?php _e('Edit') ?></a></p>
    124 
    125 <div id='timestampdiv'><?php touch_time(($action == 'edit')); ?></div>
     123&nbsp;<a href="#edit_timestamp" class="edit-timestamp" tabindex='4'><?php _e('Edit') ?></a></p>
     124
     125<div id='timestampdiv'><?php touch_time(($action == 'edit'),1,4); ?></div>
    126126<?php endif; ?>
    127127
     
    217217
    218218<div id="category-adder" class="wp-hidden-children">
    219     <h4><a id="category-add-toggle" href="#category-add"><?php _e( '+ Add New Category' ); ?></a></h4>
     219    <h4><a id="category-add-toggle" href="#category-add" tabindex="3"><?php _e( '+ Add New Category' ); ?></a></h4>
    220220    <p id="category-add" class="wp-hidden-child">
    221         <input type="text" name="newcat" id="newcat" class="form-required form-input-tip" value="<?php _e( 'New category name' ); ?>" />
    222         <?php wp_dropdown_categories( array( 'hide_empty' => 0, 'name' => 'newcat_parent', 'orderby' => 'name', 'hierarchical' => 1, 'show_option_none' => __('Parent category') ) ); ?>
    223         <input type="button" id="category-add-sumbit" class="add:categorychecklist:categorydiv button" value="<?php _e( 'Add' ); ?>" />
     221        <input type="text" name="newcat" id="newcat" class="form-required form-input-tip" value="<?php _e( 'New category name' ); ?>" tabindex="3" />
     222        <?php wp_dropdown_categories( array( 'hide_empty' => 0, 'name' => 'newcat_parent', 'orderby' => 'name', 'hierarchical' => 1, 'show_option_none' => __('Parent category'), 'tab_index' => 3 ) ); ?>
     223        <input type="button" id="category-add-sumbit" class="add:categorychecklist:categorydiv button" value="<?php _e( 'Add' ); ?>" tabindex="3" />
    224224        <?php wp_nonce_field( 'add-category', '_ajax_nonce', false ); ?>
    225225        <span id="category-ajax-response"></span>
     
    228228
    229229<ul id="category-tabs">
    230     <li class="ui-tabs-selected"><a href="#categories-all"><?php _e( 'All Categories' ); ?></a></li>
    231     <li class="wp-no-js-hidden"><a href="#categories-pop"><?php _e( 'Most Used' ); ?></a></li>
     230    <li class="ui-tabs-selected"><a href="#categories-all" tabindex="3"><?php _e( 'All Categories' ); ?></a></li>
     231    <li class="wp-no-js-hidden"><a href="#categories-pop" tabindex="3"><?php _e( 'Most Used' ); ?></a></li>
    232232</ul>
    233233
     
    239239
    240240<div id="categories-pop" class="ui-tabs-panel" style="display: none;">
    241     <ul id="categorychecklist-pop" class="categorychecklist form-no-clear">
     241    <ul id="categorychecklist-pop" class="categorychecklist form-no-clear" >
    242242        <?php wp_popular_terms_checklist('category'); ?>
    243243    </ul>
  • trunk/wp-admin/includes/template.php

    r7468 r7472  
    193193        ?>
    194194
    195         <li id="<?php echo $id; ?>">
     195        <li id="<?php echo $id; ?>" >
    196196            <label class="selectit" for="in-<?php echo $id; ?>">
    197                 <input id="in-<?php echo $id; ?>" type="checkbox" value="<?php echo (int) $category->term_id; ?>" />
     197            <input id="in-<?php echo $id; ?>" type="checkbox" value="<?php echo (int) $category->term_id; ?>" />
    198198                <?php echo wp_specialchars( apply_filters( 'the_category', $category->name ) ); ?>
    199199            </label>
  • trunk/wp-includes/category-template.php

    r7130 r7472  
    217217        'selected' => 0, 'hierarchical' => 0,
    218218        'name' => 'cat', 'class' => 'postform',
    219         'depth' => 0
     219        'depth' => 0, 'tab_index' => 0
    220220    );
    221221
     
    226226    extract( $r );
    227227
     228    $tab_index_attribute = '';
     229    if ( (int) $tab_index > 0 )
     230        $tab_index_attribute = " tabindex=\"$tab_index\"";
     231
    228232    $categories = get_categories($r);
    229233
    230234    $output = '';
    231235    if ( ! empty($categories) ) {
    232         $output = "<select name='$name' id='$name' class='$class'>\n";
     236        $output = "<select name='$name' id='$name' class='$class' $tab_index_attribute>\n";
    233237
    234238        if ( $show_option_all ) {
Note: See TracChangeset for help on using the changeset viewer.