Make WordPress Core

Opened 9 years ago

Last modified 8 years ago

#10122 closed task (blessed)

create metaboxes for hierarchical taxonomies — at Version 6

Reported by: nicomollet Owned by: filosofo
Milestone: 3.0 Priority: normal
Severity: minor Version: 2.8
Component: Taxonomy Keywords: has-patch
Focuses: Cc:

Description (last modified by dd32)

edit by dd32:

The posts page only contains metaboxes for flat taxonomiese (non-hierarchical ones). It should also support custom taxonomies which are parent-child(hierarchical).

original desc from nicomollet:

WP2.8 new taxonomy features make us create new taxonomies. Example in http://justintadlock.com/archives/2009/05/06/custom-taxonomies-in-wordpress-28

You can make new taxonomy tags "Animals" with this simple line of code :

register_taxonomy( 'animals', 'post', array( 'hierarchical' => false, 'label' => 'Animals' ) );

But it seems possible to create new taxonomy categories, like "Rating" (G, PG, PG-13, R, NC-17) with :

register_taxonomy( 'rating', 'post', array('hierarchical' => true,  'label' => 'Rating') );

This last line of code does nothing at all. It is supposed to work ? Maybe it needs to be implemented. Thanx

Change History (6)

#1 @nicomollet
9 years ago

I may precise that the last line of code

register_taxonomy( 'rating', 'post', array('hierarchical' => true,  'label' => 'Rating') );

does not create "automatic meta boxes" and "manage screens" like "hierarchical => false" does.

#2 @Denis-de-Bernardy
9 years ago

  • Keywords needs-patch added
  • Milestone changed from Unassigned to 2.9

I suspect it's by design - the hierarchical attribute would imply that the rating can't be added as a tag.

#3 @Denis-de-Bernardy
9 years ago

  • Milestone changed from 2.9 to Future Release

#4 @ryan
9 years ago

This is by design. Support for categories will be added later.

#5 @harrym
9 years ago

Any chance of this making it into 2.9?

#6 @dd32
9 years ago

  • Description modified (diff)
  • Summary changed from register_taxonomy only for tags, not for categories ? to create metaboxes for hierarchical taxonomies

Any chance of this making it into 2.9?

I'm working on something like that, but no guarantee's if it'll make it into any version.. Is anyone else even attempting that?

Note: See TracTickets for help on using tickets.