Index: wp-includes/taxonomy.php
===================================================================
--- wp-includes/taxonomy.php (revision 12794)
+++ wp-includes/taxonomy.php (working copy)
@@ -194,6 +194,9 @@
$args['name'] = $taxonomy;
$args['object_type'] = (array) $object_type;
$wp_taxonomies[$taxonomy] = (object) $args;
+
+ //register callback handling for metabox
+ add_filter('wp_ajax_add-'.$taxonomy, '_wp_ajax_add_hierarchical_term');
}
/**
@@ -1573,7 +1576,7 @@
* slug has to be globally unique for every taxonomy.
*
* The way this works is that if the taxonomy that the term belongs to is
- * heirarchical and has a parent, it will append that parent to the $slug.
+ * hierarchical and has a parent, it will append that parent to the $slug.
*
* If that still doesn't return an unique slug, then it try to append a number
* until it finds a number that is truely unique.
Index: wp-includes/category-template.php
===================================================================
--- wp-includes/category-template.php (revision 12794)
+++ wp-includes/category-template.php (working copy)
@@ -356,7 +356,7 @@
if ( (int) $tab_index > 0 )
$tab_index_attribute = " tabindex=\"$tab_index\"";
- $categories = get_categories( $r );
+ $categories = get_terms( $taxonomy, $r );
$name = esc_attr($name);
$class = esc_attr($class);
Index: wp-admin/admin-ajax.php
===================================================================
--- wp-admin/admin-ajax.php (revision 12794)
+++ wp-admin/admin-ajax.php (working copy)
@@ -200,6 +200,82 @@
$x->send();
}
+function _wp_ajax_add_hierarchical_term() {
+ $action = $_POST['action'];
+ $taxonomy = get_taxonomy(substr($action, 4));
+ check_ajax_referer( $action );
+ if ( !current_user_can( 'manage_categories' ) )
+ die('-1');
+ $names = explode(',', $_POST['new'.$taxonomy->name]);
+ if ( 0 > $parent = (int) $_POST['new'.$taxonomy->name.'_parent'] )
+ $parent = 0;
+ if($taxonomy->name == 'category') {
+ $post_category = isset($_POST['post_category'])? (array) $_POST['post_category'] : array();
+ }
+ else {
+ $post_category = (isset($_POST['tax_input']) && isset($_POST['tax_input'][$taxonomy->name])) ? (array) $_POST['tax_input'][$taxonomy->name] : array();
+ }
+ $checked_categories = array_map( 'absint', (array) $post_category );
+ $popular_ids = wp_popular_terms_checklist($taxonomy->name, 0, 10, false);
+
+ foreach ( $names as $cat_name ) {
+ $cat_name = trim($cat_name);
+ $category_nicename = sanitize_title($cat_name);
+ if ( '' === $category_nicename )
+ continue;
+ if(!($cat_id = is_term($cat_name, $taxonomy->name, $parent))) {
+ $new_term = wp_insert_term($cat_name, $taxonomy->name, array('parent' => $parent));
+ $cat_id = $new_term['term_id'];
+ }
+ $checked_categories[] = $cat_id;
+ if ( $parent ) // Do these all at once in a second
+ continue;
+ $category = get_term( $cat_id, $taxonomy->name );
+ ob_start();
+ wp_terms_checklist( 0, array('taxonomy'=>$taxonomy->name, 'descendants_and_self'=>$cat_id, 'selected_cats'=>$checked_categories, 'popular_cats'=>$popular_ids));
+ $data = ob_get_contents();
+ ob_end_clean();
+ $add = array(
+ 'what' => $taxonomy->name,
+ 'id' => $cat_id,
+ 'data' => str_replace( array("\n", "\t"), '', $data),
+ 'position' => -1
+ );
+ }
+ if ( $parent ) { // Foncy - replace the parent and all its children
+ $parent = get_term( $parent, $taxonomy->name );
+ $term_id = $parent->term_id;
+
+ while ( $parent->parent ) { // get the top parent
+ $parent = &get_term( $parent->parent, $taxonomy->name );
+ if ( is_wp_error( $parent ) )
+ break;
+ $term_id = $parent->term_id;
+ }
+
+ ob_start();
+ wp_terms_checklist( 0, array('taxonomy' => $taxonomy->name, 'descendants_and_self' => $term_id, 'selected_cats' => $checked_categories, 'popular_cats' => $popular_ids));
+ $data = ob_get_contents();
+ ob_end_clean();
+ $add = array(
+ 'what' => $taxonomy->name,
+ 'id' => $term_id,
+ 'data' => str_replace( array("\n", "\t"), '', $data),
+ 'position' => -1
+ );
+ }
+
+ ob_start();
+ wp_dropdown_categories( array( 'taxonomy' => $taxonomy->name, 'hide_empty' => 0, 'name' => 'new'.$taxonomy->name.'_parent', 'orderby' => 'name', 'hierarchical' => 1, 'show_option_none' => __('Parent category') ) );
+ $sup = ob_get_contents();
+ ob_end_clean();
+ $add['supplemental'] = array( 'newcat_parent' => $sup );
+
+ $x = new WP_Ajax_Response( $add );
+ $x->send();
+}
+
+
$id = isset($_POST['id'])? (int) $_POST['id'] : 0;
switch ( $action = $_POST['action'] ) :
case 'delete-comment' : // On success, die with time() instead of 1
@@ -409,70 +485,6 @@
_wp_ajax_delete_comment_response( $comment->comment_ID );
die( '0' );
break;
-case 'add-category' : // On the Fly
- check_ajax_referer( $action );
- if ( !current_user_can( 'manage_categories' ) )
- die('-1');
- $names = explode(',', $_POST['newcat']);
- if ( 0 > $parent = (int) $_POST['newcat_parent'] )
- $parent = 0;
- $post_category = isset($_POST['post_category'])? (array) $_POST['post_category'] : array();
- $checked_categories = array_map( 'absint', (array) $post_category );
- $popular_ids = wp_popular_terms_checklist('category', 0, 10, false);
-
- foreach ( $names as $cat_name ) {
- $cat_name = trim($cat_name);
- $category_nicename = sanitize_title($cat_name);
- if ( '' === $category_nicename )
- continue;
- $cat_id = wp_create_category( $cat_name, $parent );
- $checked_categories[] = $cat_id;
- if ( $parent ) // Do these all at once in a second
- continue;
- $category = get_category( $cat_id );
- ob_start();
- wp_category_checklist( 0, $cat_id, $checked_categories, $popular_ids );
- $data = ob_get_contents();
- ob_end_clean();
- $add = array(
- 'what' => 'category',
- 'id' => $cat_id,
- 'data' => str_replace( array("\n", "\t"), '', $data),
- 'position' => -1
- );
- }
- if ( $parent ) { // Foncy - replace the parent and all its children
- $parent = get_category( $parent );
- $term_id = $parent->term_id;
-
- while ( $parent->parent ) { // get the top parent
- $parent = &get_category( $parent->parent );
- if ( is_wp_error( $parent ) )
- break;
- $term_id = $parent->term_id;
- }
-
- ob_start();
- wp_category_checklist( 0, $term_id, $checked_categories, $popular_ids, null, false );
- $data = ob_get_contents();
- ob_end_clean();
- $add = array(
- 'what' => 'category',
- 'id' => $term_id,
- 'data' => str_replace( array("\n", "\t"), '', $data),
- 'position' => -1
- );
- }
-
- ob_start();
- wp_dropdown_categories( array( 'hide_empty' => 0, 'name' => 'newcat_parent', 'orderby' => 'name', 'hierarchical' => 1, 'show_option_none' => __('Parent category') ) );
- $sup = ob_get_contents();
- ob_end_clean();
- $add['supplemental'] = array( 'newcat_parent' => $sup );
-
- $x = new WP_Ajax_Response( $add );
- $x->send();
- break;
case 'add-link-category' : // On the Fly
check_ajax_referer( $action );
if ( !current_user_can( 'manage_categories' ) )
Index: wp-admin/includes/meta-boxes.php
===================================================================
--- wp-admin/includes/meta-boxes.php (revision 12794)
+++ wp-admin/includes/meta-boxes.php (working copy)
@@ -268,38 +268,45 @@
*
* @param object $post
*/
-function post_categories_meta_box($post) {
-?>
-
+function post_categories_meta_box($post, $box) {
+ $defaults = array('taxonomy' => 'category');
+ if(!isset($box['args']) || !is_array($args = $box['args'])) {
+ $args = array();
+ }
+ extract(array_merge($defaults, $args));
+ ?>
+
+ term_id, $popular_cats ) ? ' class="popular-category"' : '';
- $output .= "\n" . '';
+ $output .= "\n" . '';
}
function end_el(&$output, $category, $depth, $args) {
@@ -486,31 +493,57 @@
* @param unknown_type $popular_cats
*/
function wp_category_checklist( $post_id = 0, $descendants_and_self = 0, $selected_cats = false, $popular_cats = false, $walker = null, $checked_ontop = true ) {
+ wp_terms_checklist($post_id,
+ array(
+ 'taxonomy' => 'category',
+ 'descendants_and_self' => $descendants_and_self,
+ 'selected_cats' => $selected_cats,
+ 'popular_cats' => $popular_cats,
+ 'walker' => $walker
+ ));
+ }
+
+/**
+ * Taxonomy independent version of wp_category_checklist
+ *
+ * @param int $post_id
+ * @param array $args
+ */
+function wp_terms_checklist($post_id = 0, $args = array()) {
+ $defaults = array(
+ 'descendants_and_self' => 0,
+ 'selected_cats' => false,
+ 'popular_cats' => false,
+ 'walker' => null,
+ 'taxonomy' => 'category'
+ );
+ extract(array_merge($defaults, $args));
+
if ( empty($walker) || !is_a($walker, 'Walker') )
$walker = new Walker_Category_Checklist;
$descendants_and_self = (int) $descendants_and_self;
- $args = array();
+ $args = array('taxonomy' => $taxonomy);
if ( is_array( $selected_cats ) )
$args['selected_cats'] = $selected_cats;
elseif ( $post_id )
- $args['selected_cats'] = wp_get_post_categories($post_id);
+ $args['selected_cats'] = wp_get_object_terms($post_id, $taxonomy, array_merge($args, array('fields' => 'ids')));
else
$args['selected_cats'] = array();
if ( is_array( $popular_cats ) )
$args['popular_cats'] = $popular_cats;
else
- $args['popular_cats'] = get_terms( 'category', array( 'fields' => 'ids', 'orderby' => 'count', 'order' => 'DESC', 'number' => 10, 'hierarchical' => false ) );
+ $args['popular_cats'] = get_terms( $taxonomy, array( 'fields' => 'ids', 'orderby' => 'count', 'order' => 'DESC', 'number' => 10, 'hierarchical' => false ) );
if ( $descendants_and_self ) {
- $categories = get_categories(array('child_of' => $descendants_and_self, 'hierarchical' => 0, 'hide_empty' => 0));
- $self = get_category( $descendants_and_self );
+ $categories = (array) get_terms($taxonomy, array( 'child_of' => $descendants_and_self, 'hierarchical' => 0, 'hide_empty' => 0 ) );
+ $self = get_term( $descendants_and_self, $taxonomy );
array_unshift( $categories, $self );
} else {
- $categories = get_categories(array('get' => 'all'));
+ $categories = (array) get_terms($taxonomy, array('get' => 'all'));
}
if ( $checked_ontop ) {
@@ -547,7 +580,7 @@
global $post_ID;
if ( $post_ID )
- $checked_categories = wp_get_post_categories($post_ID);
+ $checked_categories = wp_get_object_terms($post_ID, 'category', array('fields'=>'ids'));
else
$checked_categories = array();
@@ -558,7 +591,7 @@
$popular_ids[] = $category->term_id;
if ( !$echo ) // hack for AJAX use
continue;
- $id = "popular-category-$category->term_id";
+ $id = "popular-$taxonomy-$category->term_id";
$checked = in_array( $category->term_id, $checked_categories ) ? 'checked="checked"' : '';
?>
Index: wp-admin/js/post.dev.js
===================================================================
--- wp-admin/js/post.dev.js (revision 12794)
+++ wp-admin/js/post.dev.js (working copy)
@@ -228,7 +228,7 @@
})(jQuery);
jQuery(document).ready( function($) {
- var catAddAfter, stamp, visibility, sticky = '', post = 'post' == pagenow || 'post-new' == pagenow, page = 'page' == pagenow || 'page-new' == pagenow;
+ var stamp, visibility, sticky = '', post = 'post' == pagenow || 'post-new' == pagenow, page = 'page' == pagenow || 'page-new' == pagenow;
// postboxes
if ( post ) {
@@ -253,35 +253,55 @@
}
// categories
- if ( $('#categorydiv').length ) {
+ $('.categorydiv').each(function(){
+ var this_id = $(this).attr('id'), noSyncChecks = false, syncChecks, catAddAfter, popularCats;
+ var taxonomy_parts = this_id.split('-');
+ taxonomy_parts.shift();
+ var taxonomy = taxonomy_parts.join('-');
+ var settingName = taxonomy+'_tab';
+ if(taxonomy == 'category')
+ settingName = 'cats';
+
// TODO: move to jQuery 1.3+, support for multiple hierarchical taxonomies, see wp-lists.dev.js
- $('a', '#category-tabs').click(function(){
+ $('a', '#'+taxonomy+'-tabs').click(function(){
var t = $(this).attr('href');
$(this).parent().addClass('tabs').siblings('li').removeClass('tabs');
- $('#category-tabs').siblings('.tabs-panel').hide();
+ $('#'+taxonomy+'-tabs').siblings('.tabs-panel').hide();
$(t).show();
- if ( '#categories-all' == t )
- deleteUserSetting('cats');
+ if ( '#'+taxonomy+'-all' == t )
+ deleteUserSetting(settingName);
else
- setUserSetting('cats','pop');
+ setUserSetting(settingName,'pop');
return false;
});
- if ( getUserSetting('cats') )
- $('a[href="#categories-pop"]', '#category-tabs').click();
+
+ if ( getUserSetting(settingName) )
+ $('a[href="#'+taxonomy+'-pop"]', '#'+taxonomy+'-tabs').click();
// Ajax Cat
- $('#newcat').one( 'focus', function() { $(this).val( '' ).removeClass( 'form-input-tip' ) } );
- $('#category-add-sumbit').click( function(){ $('#newcat').focus(); } );
-
+ $('#new'+taxonomy).one( 'focus', function() { $(this).val( '' ).removeClass( 'form-input-tip' ) } );
+ $('#'+taxonomy+'-add-submit').click(function(){$('#new'+taxonomy).focus();});
+
+ syncChecks = function() {
+ if ( noSyncChecks )
+ return;
+ noSyncChecks = true;
+ var th = jQuery(this), c = th.is(':checked'), id = th.val().toString();
+ $('#in-'+taxonomy+'-' + id + ', #in-'+taxonomy+'-category-' + id).attr( 'checked', c );
+ noSyncChecks = false;
+ };
+
+
+
catAddBefore = function( s ) {
- if ( !$('#newcat').val() )
+ if ( !$('#new'+taxonomy).val() )
return false;
- s.data += '&' + $( ':checked', '#categorychecklist' ).serialize();
+ s.data += '&' + $( ':checked', '#'+taxonomy+'checklist' ).serialize();
return s;
};
catAddAfter = function( r, s ) {
- var sup, drop = $('#newcat_parent');
+ var sup, drop = $('#new'+taxonomy+'_parent');
if ( 'undefined' != s.parsed.responses[0] && (sup = s.parsed.responses[0].supplemental.newcat_parent) ) {
drop.before(sup);
@@ -289,25 +309,24 @@
}
};
- $('#categorychecklist').wpList({
+ $('#'+taxonomy+'checklist').wpList({
alt: '',
- response: 'category-ajax-response',
+ response: taxonomy+'-ajax-response',
addBefore: catAddBefore,
addAfter: catAddAfter
});
-
- $('#category-add-toggle').click( function() {
- $('#category-adder').toggleClass( 'wp-hidden-children' );
- $('a[href="#categories-all"]', '#category-tabs').click();
+ $('#'+taxonomy+'-add-toggle').click( function() {
+ $('#'+taxonomy+'-adder').toggleClass( 'wp-hidden-children' );
+ $('a[href="#'+taxonomy+'-all"]', '#'+taxonomy+'-tabs').click();
return false;
});
- $('#categorychecklist').children('li.popular-category').add( $('#categorychecklist-pop').children() ).find(':checkbox').live( 'click', function(){
+ $('#'+taxonomy+'checklist').children('li.popular-category').add( $('#'+taxonomy+'checklist-pop').children() ).find(':checkbox').live( 'click', function(){
var t = $(this), c = t.is(':checked'), id = t.val();
- $('#in-category-' + id + ', #in-popular-category-' + id).attr( 'checked', c );
+ $('#in-'+taxonomy+'-' + id + ', #in-popular-'+taxonomy+'-' + id).attr( 'checked', c );
});
- } // end cats
+ }); // end cats
// Custom Fields
if ( $('#postcustom').length ) {
Index: wp-admin/edit-form-advanced.php
===================================================================
--- wp-admin/edit-form-advanced.php (revision 12794)
+++ wp-admin/edit-form-advanced.php (working copy)
@@ -94,17 +94,17 @@
// all tag-style taxonomies
foreach ( get_object_taxonomies($post_type) as $tax_name ) {
+ $taxonomy = get_taxonomy($tax_name);
+ $label = isset($taxonomy->label) ? esc_attr($taxonomy->label) : $tax_name;
+
if ( !is_taxonomy_hierarchical($tax_name) ) {
- $taxonomy = get_taxonomy($tax_name);
- $label = isset($taxonomy->label) ? esc_attr($taxonomy->label) : $tax_name;
-
add_meta_box('tagsdiv-' . $tax_name, $label, 'post_tags_meta_box', $post_type, 'side', 'core');
}
+ else {
+ add_meta_box($tax_name.'div', $label, 'post_categories_meta_box', 'post', 'side', 'core', array('taxonomy'=>$tax_name));
+ }
}
-if ( is_object_in_taxonomy($post_type, 'category') )
- add_meta_box('categorydiv', __('Categories'), 'post_categories_meta_box', $post_type, 'side', 'core');
-
if ( post_type_supports($post_type, 'page-attributes') )
add_meta_box('pageparentdiv', __('Attributes'), 'page_attributes_meta_box', $post_type, 'side', 'core');
Index: wp-admin/css/colors-classic.dev.css
===================================================================
--- wp-admin/css/colors-classic.dev.css (revision 12794)
+++ wp-admin/css/colors-classic.dev.css (working copy)
@@ -110,11 +110,11 @@
}
div.tabs-panel,
-ul#category-tabs li.tabs {
+ul.category-tabs li.tabs {
border-color: #dfdfdf;
}
-ul#category-tabs li.tabs {
+ul.category-tabs li.tabs {
background-color: #f1f1f1;
}
@@ -384,7 +384,7 @@
background: #faf9f7 !important;
}
-#side-sortables #category-tabs .tabs a {
+#side-sortables .category-tabs .tabs a {
color: #333;
}
@@ -1463,7 +1463,7 @@
background-color: #f5f5f5;
}
-#post-body ul#category-tabs li.tabs a {
+#post-body ul.category-tabs li.tabs a {
color: #333;
}
Index: wp-admin/css/press-this.dev.css
===================================================================
--- wp-admin/css/press-this.dev.css (revision 12794)
+++ wp-admin/css/press-this.dev.css (working copy)
@@ -115,7 +115,7 @@
}
#tagsdiv-post_tag h3,
-#categorydiv h3 {
+.categorydiv h3 {
cursor: pointer;
}
@@ -308,15 +308,15 @@
display: none;
}
-#category-adder {
+.category-adder {
padding: 4px 0;
}
-#category-adder h4 {
+.category-adder h4 {
margin: 0 0 8px;
}
-#category-add input {
+.category-add input {
width: 94%;
font-family: Verdana,Arial,Helvetica,sans-serif;
font-size: 13px;
@@ -324,7 +324,7 @@
padding: 3px;
}
-#category-add select {
+.category-add select {
width: 70%;
-x-system-font: none;
border-style: solid;
@@ -338,24 +338,24 @@
vertical-align: top;
}
-#category-add input,
-#category-add-sumbit {
+.category-add input,
+.category-add-sumbit {
width: auto;
}
/* Categories */
-#categorydiv ul,
+.categorydiv ul,
#linkcategorydiv ul {
list-style: none;
padding: 0;
margin: 0;
}
-#categorydiv ul.categorychecklist ul {
+.categorydiv ul.categorychecklist ul {
margin-left: 18px;
}
-#categorydiv div.tabs-panel {
+.categorydiv div.tabs-panel {
height: 140px;
overflow: auto;
}
Index: wp-admin/css/colors-fresh.dev.css
===================================================================
--- wp-admin/css/colors-fresh.dev.css (revision 12794)
+++ wp-admin/css/colors-fresh.dev.css (working copy)
@@ -110,11 +110,11 @@
}
div.tabs-panel,
-ul#category-tabs li.tabs {
+ul.category-tabs li.tabs {
border-color: #dfdfdf;
}
-ul#category-tabs li.tabs {
+ul.category-tabs li.tabs {
background-color: #f1f1f1;
}
@@ -380,7 +380,7 @@
border-color: #dfdfdf;
}
-#side-sortables #category-tabs .tabs a {
+#side-sortables .category-tabs .tabs a {
color: #333;
}
@@ -1458,7 +1458,7 @@
background-color: #f5f5f5;
}
-#post-body ul#category-tabs li.tabs a {
+#post-body ul.category-tabs li.tabs a {
color: #333;
}
Index: wp-admin/css/wp-admin.dev.css
===================================================================
--- wp-admin/css/wp-admin.dev.css (revision 12794)
+++ wp-admin/css/wp-admin.dev.css (working copy)
@@ -1928,36 +1928,36 @@
/* Categories */
-#category-adder {
+.category-adder {
margin-left: 120px;
padding: 4px 0;
}
-#category-adder h4 {
+.category-adder h4 {
margin: 0 0 8px;
}
-#side-sortables #category-adder {
+#side-sortables .category-adder {
margin: 0;
}
-#post-body #category-add input, #category-add select {
+#post-body .category-add input, .category-add select {
width: 30%;
}
-#side-sortables #category-add input {
+#side-sortables .category-add input {
width: 94%;
}
-#side-sortables #category-add select {
+#side-sortables .category-add select {
width: 100%;
}
-#category-add input#category-add-sumbit {
+#side-sortables .category-add input.category-add-sumbit, #post-body .category-add input.category-add input.category-add-sumbit {
width: auto;
}
-#post-body ul#category-tabs {
+#post-body ul.category-tabs {
float: left;
width: 120px;
text-align: right;
@@ -1966,11 +1966,11 @@
padding: 0;
}
-#post-body ul#category-tabs li {
+#post-body ul.category-tabs li {
padding: 8px;
}
-#post-body ul#category-tabs li.tabs {
+#post-body ul.category-tabs li.tabs {
-moz-border-radius: 3px 0 0 3px;
-webkit-border-top-left-radius: 3px;
-webkit-border-bottom-left-radius: 3px;
@@ -1980,12 +1980,12 @@
border-bottom-left-radius: 3px;
}
-#post-body ul#category-tabs li.tabs a {
+#post-body ul.category-tabs li.tabs a {
font-weight: bold;
text-decoration: none;
}
-#categorydiv div.tabs-panel,
+.categorydiv div.tabs-panel,
#linkcategorydiv div.tabs-panel {
height: 200px;
overflow: auto;
@@ -1994,32 +1994,32 @@
border-width: 1px;
}
-#post-body #categorydiv div.tabs-panel,
+#post-body .categorydiv div.tabs-panel,
#post-body #linkcategorydiv div.tabs-panel {
margin: 0 5px 0 125px;
}
-#side-sortables #category-tabs li {
+#side-sortables .category-tabs li {
display: inline;
padding-right: 8px;
}
-#side-sortables #category-tabs a {
+#side-sortables .category-tabs a {
text-decoration: none;
}
-#side-sortables #category-tabs {
+#side-sortables .category-tabs {
margin-bottom: 3px;
}
-#categorydiv ul,
+.categorydiv ul,
#linkcategorydiv ul {
list-style: none;
padding: 0;
margin: 0;
}
-#categorydiv ul.categorychecklist ul,
+.categorydiv ul.categorychecklist ul,
#linkcategorydiv ul.categorychecklist ul {
margin-left: 18px;
}
@@ -2030,32 +2030,32 @@
line-height: 19px;
}
-#category-adder h4 {
+.category-adder h4 {
margin-top: 4px;
margin-bottom: 0px;
}
-#categorydiv .tabs-panel {
+.categorydiv .tabs-panel {
border-width: 3px;
border-style: solid;
}
-ul#category-tabs {
+ul.category-tabs {
margin-top: 12px;
}
-ul#category-tabs li.tabs {
+ul.category-tabs li.tabs {
border-style: solid solid none;
border-width: 1px 1px 0;
}
-#post-body #category-tabs li.tabs {
+#post-body .category-tabs li.tabs {
border-style: solid none solid solid;
border-width: 1px 0 1px 1px;
margin-right: -1px;
}
-ul#category-tabs li {
+ul.category-tabs li {
padding: 5px 8px;
-moz-border-radius: 3px 3px 0 0;
-webkit-border-top-left-radius: 3px;
Index: wp-admin/css/wp-admin-rtl.css
===================================================================
--- wp-admin/css/wp-admin-rtl.css (revision 12794)
+++ wp-admin/css/wp-admin-rtl.css (working copy)
@@ -294,11 +294,11 @@
margin-left: 4px;
}
/* Categories */
-#category-adder {
+.category-adder {
margin-left: 0;
margin-right: 120px;
}
-#post-body ul#category-tabs li.tabs {
+#post-body ul.category-tabs li.tabs {
-moz-border-radius: 0 3px 3px 0;
-webkit-border-top-left-radius: 0;
-webkit-border-top-right-radius: 3px;
@@ -309,22 +309,22 @@
border-bottom-left-radius: 0;
border-bottom-right-radius: 3px;
}
-#post-body ul#category-tabs {
+#post-body ul.category-tabs {
float: right;
text-align: left;
margin: 0 0 0 -120px;
}
-#post-body #categorydiv div.tabs-panel,
+#post-body .categorydiv div.tabs-panel,
#post-body #linkcategorydiv div.tabs-panel {
margin: 0 120px 0 5px;
}
/* 1800 - 2000
=================================== */
-#side-sortables #category-tabs li {
+#side-sortables .category-tabs li {
padding-right: 0;
padding-left: 8px;
}
-#categorydiv ul.categorychecklist ul,
+.categorydiv ul.categorychecklist ul,
#linkcategorydiv ul.categorychecklist ul {
margin-left: 0;
margin-right: 18px;