Make WordPress Core

Opened 12 years ago

Closed 11 years ago

Last modified 11 years ago

#20930 closed enhancement (fixed)

register_taxonomy show_in_menu option

Reported by: wpsmith's profile wpsmith Owned by: ocean90's profile ocean90
Milestone: 3.7 Priority: normal
Severity: normal Version:
Component: Taxonomy Keywords: has-patch 3.6-early
Focuses: Cc:

Description

Shouldn't taxonomies have a show_in_menu option for taxonomies as well. Of course, this would be the same as custom post types affecting the registration and the $parent_file.

The original attachment has the parent file logic via the filter, 'parent_file'.

Attachments (4)

taxonomy_submenu.php (1.2 KB) - added by wpsmith 12 years ago.
20930.patch (2.3 KB) - added by ocean90 12 years ago.
20930.diff (2.5 KB) - added by wonderboymusic 11 years ago.
20930.2.diff (3.9 KB) - added by ocean90 11 years ago.

Download all attachments as: .zip

Change History (13)

#1 @ryanduff
12 years ago

  • Cc ryan@… added
  • Keywords needs-patch dev-feedback added; has-patch needs-testing removed

Yes. I think you should be able to show the menu and hide the metabox.

show_in_ui would set both to true, but you can set show_in_ui to false and show_in_menu to true to get the desired result and behavior you get with register_post_type

+1 for making this happen.

@ocean90
12 years ago

#2 @ocean90
12 years ago

  • Keywords has-patch 3.6-early added; needs-patch dev-feedback removed
  • Milestone changed from Awaiting Review to 3.5

Sad that this has missed the boat. Was on my plan for [21948].

#3 @ocean90
12 years ago

  • Milestone changed from 3.5 to Future Release

#4 @gableroux
12 years ago

Can't figure out why this is not in wordpress core yet :\, very usefull.

#5 @wonderboymusic
11 years ago

  • Milestone changed from Future Release to 3.7

was exploding, I refreshed

#6 @ocean90
11 years ago

Created #25150 for the is_null() and doc fixes from 20930.diff.

Will do a refresh if it's in.

@ocean90
11 years ago

#7 @ocean90
11 years ago

  • Owner set to ocean90
  • Resolution set to fixed
  • Status changed from new to closed

In 25133:

Introduce show_in_menu for register_taxonomy.

Accepts boolean: true to show, false to hide. If not set, the default is inherited from show_ui.

fixes #20930.

#8 follow-up: @ciantic
11 years ago

Now the "show_in_menu" works differently than "show_in_menu" in register_post_type. I don't see a reason why.

In register_post_type one can set "show_in_menu" as a string so that it appears in certain admin menu. With register_taxonomy it's not possible to relocate menu item.

#9 in reply to: ↑ 8 @SergeyBiryukov
11 years ago

Replying to ciantic:

In register_post_type one can set "show_in_menu" as a string so that it appears in certain admin menu. With register_taxonomy it's not possible to relocate menu item.

Taxonomy is tied to an object type, so I guess relocating it make less sense than relocating a post type item.

However, I've just noticed that the parameter description is inaccurate, see #27943.

Note: See TracTickets for help on using tickets.