Make WordPress Core


Ignore:
Timestamp:
03/10/2008 05:54:46 AM (18 years ago)
Author:
ryan
Message:

Hide moderation count bubble when no comments are awaiting moderation. Props filosofo. fixes #6010

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/menu.php

    r7050 r7200  
    1818$awaiting_mod = $wpdb->get_var("SELECT COUNT(*) FROM $wpdb->comments WHERE comment_approved = '0'");
    1919$menu[15] = array(__('Design'), 'switch_themes', 'themes.php');
    20 $menu[20] = array( sprintf( __('Comments %s'), "<span id='awaiting-mod'><span class='comment-count'>$awaiting_mod</span></span>" ), 'edit_posts', 'edit-comments.php');
     20$menu[20] = array( sprintf( __('Comments %s'), "<span id='awaiting-mod' class='count-$awaiting_mod'><span class='comment-count'>$awaiting_mod</span></span>" ), 'edit_posts', 'edit-comments.php');
    2121$menu[30] = array(__('Settings'), 'manage_options', 'options-general.php');
    2222$menu[35] = array(__('Plugins'), 'activate_plugins', 'plugins.php');
Note: See TracChangeset for help on using the changeset viewer.