From 249451642046479e73a39101208fa18953258372 Mon Sep 17 00:00:00 2001 From: Peter Westwood Date: Sat, 22 Mar 2008 09:14:49 +0000 Subject: [PATCH] Improve the tabindex's on the Write>Post page. Need to do the others too. git-svn-id: https://develop.svn.wordpress.org/trunk@7472 602fd350-edb4-49c9-b593-d223f7449a82 --- wp-admin/edit-form-advanced.php | 22 +++++++++++----------- wp-admin/includes/template.php | 4 ++-- wp-includes/category-template.php | 8 ++++++-- 3 files changed, 19 insertions(+), 15 deletions(-) diff --git a/wp-admin/edit-form-advanced.php b/wp-admin/edit-form-advanced.php index 1c7e5eb25d..4eae30f645 100644 --- a/wp-admin/edit-form-advanced.php +++ b/wp-admin/edit-form-advanced.php @@ -84,7 +84,7 @@ else

- post_status, 'publish' ); selected( $post->post_status, 'private' );?> value='publish'> post_status ) : ?> @@ -97,7 +97,7 @@ else

-

+

-
+
@@ -216,19 +216,19 @@ endif; ?>
-

+

- - 0, 'name' => 'newcat_parent', 'orderby' => 'name', 'hierarchical' => 1, 'show_option_none' => __('Parent category') ) ); ?> - + + 0, 'name' => 'newcat_parent', 'orderby' => 'name', 'hierarchical' => 1, 'show_option_none' => __('Parent category'), 'tab_index' => 3 ) ); ?> +

@@ -238,7 +238,7 @@ endif; ?>
diff --git a/wp-admin/includes/template.php b/wp-admin/includes/template.php index c1ff2e6da4..707a133590 100644 --- a/wp-admin/includes/template.php +++ b/wp-admin/includes/template.php @@ -192,9 +192,9 @@ function wp_popular_terms_checklist( $taxonomy, $default = 0, $number = 10 ) { $id = "popular-category-$category->term_id"; ?> -
  • +
  • diff --git a/wp-includes/category-template.php b/wp-includes/category-template.php index b340923383..ba3f18fe70 100644 --- a/wp-includes/category-template.php +++ b/wp-includes/category-template.php @@ -216,7 +216,7 @@ function wp_dropdown_categories($args = '') { 'exclude' => '', 'echo' => 1, 'selected' => 0, 'hierarchical' => 0, 'name' => 'cat', 'class' => 'postform', - 'depth' => 0 + 'depth' => 0, 'tab_index' => 0 ); $defaults['selected'] = ( is_category() ) ? get_query_var('cat') : 0; @@ -225,11 +225,15 @@ function wp_dropdown_categories($args = '') { $r['include_last_update_time'] = $r['show_last_update']; extract( $r ); + $tab_index_attribute = ''; + if ( (int) $tab_index > 0 ) + $tab_index_attribute = " tabindex=\"$tab_index\""; + $categories = get_categories($r); $output = ''; if ( ! empty($categories) ) { - $output = "\n"; if ( $show_option_all ) { $show_option_all = apply_filters('list_cats', $show_option_all);