Make WordPress Core

Opened 15 years ago

Closed 15 years ago

Last modified 15 years ago

#16587 closed enhancement (duplicate)

wp_list_categories hide_empty counts unpublished posts

Reported by: grandslambert Owned by:
Priority: normal Milestone:
Component: General Version:
Severity: normal Keywords:
Cc: Focuses:

Description

The template tag wp_list_categories() has an option to hide_empty, however, this only hides categories that have no posts, no just no published posts. The result is that categories with only posts that are draft or pending show on the front end, and the links go to blank pages. It would be better if this argument for the tag would display only categories with published posts.

Change History (4)

#1 @greuben
15 years ago

Related/dupe #14084

#2 @garyc40
15 years ago

  • Keywords reporter-feedback added

I can't reproduce this when wp_list_categories() is using the default category taxonomy.

If you're using wp_list_categories() with a custom taxonomy, then this is a duplicate of #14084.

Otherwise, please paste the code snippet in which you're using wp_list_category().

#3 @grandslambert
15 years ago

  • Resolutionduplicate
  • Status newclosed

It is with a custom taxonomy and would be related to #14084 - but that also does not show any resolution. I will follow that ticket for now. Thank you.

#4 @ocean90
15 years ago

  • Keywords reporter-feedback removed
  • Milestone Awaiting Review
Note: See TracTickets for help on using tickets.