Fix up exporter. Remove more refrences to the categories table. see #4189
git-svn-id: http://svn.automattic.com/wordpress/trunk@5563 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
@@ -101,14 +101,15 @@ foreach ($scheduled as $post) {
|
||||
<?php
|
||||
$numposts = (int) $wpdb->get_var("SELECT COUNT(*) FROM $wpdb->posts WHERE post_type = 'post' AND post_status = 'publish'");
|
||||
$numcomms = (int) $wpdb->get_var("SELECT COUNT(*) FROM $wpdb->comments WHERE comment_approved = '1'");
|
||||
$numcats = (int) $wpdb->get_var("SELECT COUNT(*) FROM $wpdb->categories");
|
||||
$numcats = wp_count_terms('category');
|
||||
$numtags = wp_count_terms('post_tag');
|
||||
|
||||
$post_str = sprintf(__ngettext('%1$s <a href="%2$s" title="Posts">post</a>', '%1$s <a href="%2$s" title="Posts">posts</a>', $numposts), number_format_i18n($numposts), 'edit.php');
|
||||
$comm_str = sprintf(__ngettext('%1$s <a href="%2$s" title="Comments">comment</a>', '%1$s <a href="%2$s" title="Comments">comments</a>', $numcomms), number_format_i18n($numcomms), 'edit-comments.php');
|
||||
$cat_str = sprintf(__ngettext('%1$s <a href="%2$s" title="Categories">category</a>', '%1$s <a href="%2$s" title="Categories">categories</a>', $numcats), number_format_i18n($numcats), 'categories.php');
|
||||
?>
|
||||
|
||||
<p><?php printf(__('There are currently %1$s and %2$s, contained within %3$s.'), $post_str, $comm_str, $cat_str); ?></p>
|
||||
<p><?php printf(__('There are currently %1$s and %2$s, contained within %3$s and %4$s tags.'), $post_str, $comm_str, $cat_str, $numtags); ?></p>
|
||||
</div>
|
||||
|
||||
<?php do_action('activity_box_end'); ?>
|
||||
|
||||
Reference in New Issue
Block a user