From 2265d439568b9261f3bf46e423388523e6aa54a5 Mon Sep 17 00:00:00 2001 From: Mark Jaquith Date: Thu, 3 Apr 2008 05:02:19 +0000 Subject: [PATCH] Don't show delete checkbox for default category. HTML validation. props johnbillion. fixes #6560 for trunk git-svn-id: https://develop.svn.wordpress.org/trunk@7595 602fd350-edb4-49c9-b593-d223f7449a82 --- wp-admin/includes/template.php | 21 ++++++++++++++------- 1 file changed, 14 insertions(+), 7 deletions(-) diff --git a/wp-admin/includes/template.php b/wp-admin/includes/template.php index 3e67338f94..205dac1656 100644 --- a/wp-admin/includes/template.php +++ b/wp-admin/includes/template.php @@ -55,11 +55,12 @@ function _cat_row( $category, $level, $name_override = false ) { $output = " "; if ( absint(get_option( 'default_category' ) ) != $category->term_id ) { - $output .= ""; + $output .= ""; } else { $output .= " "; } - $output .= "$edit + $output .= " + $edit $category->description $posts_count\n\t\n"; @@ -86,11 +87,17 @@ function link_cat_row( $category ) { $category->count = number_format_i18n( $category->count ); $count = ( $category->count > 0 ) ? "$category->count" : $category->count; - $output = "" . - ' ' . - "$edit - $category->description - $count"; + $output = " + "; + if ( absint( get_option( 'default_link_category' ) ) != $category->term_id ) { + $output .= ""; + } else { + $output .= " "; + } + $output .= " + $edit + $category->description + $count"; return apply_filters( 'link_cat_row', $output ); }