[wp-trac] Re: [WordPress Trac] #9999: Beta 2.8.2 - wp_list_categories buggy hierarchy

WordPress Trac wp-trac at lists.automattic.com
Wed Jun 10 16:57:36 GMT 2009


#9999: Beta 2.8.2 - wp_list_categories buggy hierarchy
----------------------------+-----------------------------------------------
 Reporter:  eliZZZa         |        Type:  defect (bug)
   Status:  new             |    Priority:  normal      
Milestone:  Future Release  |   Component:  Template    
  Version:                  |    Severity:  normal      
 Keywords:  needs-patch     |  
----------------------------+-----------------------------------------------

Comment(by filosofo):

 Hello eliZZZa,

 Replying to [ticket:9999 eliZZZa]:
 > With child_of it does show the desired cats but without hierarchy

 Can you explain what you're expecting, and how the results differ?
 Passing a category ID as the "child_of" parameter does produce nested
 lists, in my tests.

 > With include it does not show children, even if I add depth=0

 "include" is meant to specify exactly which category ids you want to show.
 I don't think it makes sense to expect it to include the descendants of
 those specified category ids.  Perhaps we need something like
 "include_tree" to do that, or maybe we could expand "child_of" to accept
 multiple IDs.

 > With exclude it behaves mainly like the former exclude_tree but leaves a
 few subcats for no obvious reason (with their parents excluded).

 Again, since "exclude", like "include" is meant to specify exactly which
 IDs to exclude, it doesn't make sense to expect it to exclude those IDs'
 children.  That's what "exclude_tree" is for.

-- 
Ticket URL: <http://core.trac.wordpress.org/ticket/9999#comment:2>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list