WordPress.org

Make WordPress Core


Ignore:
Timestamp:
12/17/2010 11:17:41 AM (10 years ago)
Author:
scribu
Message:

Display categories again. Props garyc40. Fixes #15857

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/includes/class-wp-terms-list-table.php

    r16992 r17025  
    118118    }
    119119
    120     function display_rows() {
     120    function display_rows_or_placeholder() {
    121121        global $taxonomy;
    122122
     
    135135        $out = '';
    136136        $count = 0;
     137       
     138        $terms = array();
     139
    137140        if ( is_taxonomy_hierarchical( $taxonomy ) && !isset( $orderby ) ) {
    138141            // We'll need the full set of terms then.
     
    153156            $count = $number; // Only displaying a single page.
    154157        }
    155 
    156         echo $out;
     158       
     159        if ( empty( $terms ) ) {
     160            echo '<tr class="no-items"><td colspan="2">';
     161            $this->no_items();
     162            echo '</td></tr>';
     163        } else {
     164            echo $out;
     165        }
    157166    }
    158167
Note: See TracChangeset for help on using the changeset viewer.