WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have a group of custom post types such as "CPT A", "CPT B" and "CPT C". I display the admin page for each of these as subpages under a common Admin page.

    array ( $this, 'page_main' ),

There are also custom taxonomies for the CPTs, and some of them are shared.

What I'm to do is, in the admin pane add submenu page off the main one that links to the taxonomies in edit-tags.php.

    array( $this, 'page_taxonomy' )

The problem I encounter is that the list table doesn't fill. Any suggestions on a good/better approach are most welcome.

Just as a follow up, I want a menu that looks something like:

--Taxonomy 1
--Taxonomy 2
share|improve this question
up vote 0 down vote accepted

We could manipulate the global $menu and $submenu inside the admin_menu hook. But it's easier to let Mike Schinkel's WP Admin Menu Classes take care of it.


add_action( 'admin_menu', function()
    $plugin_page = 'wpse_114343'; 
        function() {},
    // Move the CPT Movie and remove original
    $cpt = "edit.php?post_type=movie";
    copy_admin_menu_item( $plugin_page,$cpt );
    remove_admin_menu_section( $cpt );

    // Move the CPT Page and remove original
    $cpt2 = "edit.php?post_type=page";
    copy_admin_menu_item( $plugin_page, $cpt2 );
    remove_admin_menu_section( $cpt2 );

    // Move Posts Category and Tags and remove originals
    $cat = "edit-tags.php?taxonomy=category";
    $tag = "edit-tags.php?taxonomy=post_tag";
    $tax_menu = 'edit.php';
    copy_admin_menu_item( $plugin_page, $tax_menu, $cat );
    copy_admin_menu_item( $plugin_page, $tax_menu, $tag );
    remove_admin_menu_item( $tax_menu, $cat );
    remove_admin_menu_item( $tax_menu, $tag );

manipulated wp-admin menu and sub-menu

share|improve this answer
Wow, that's awesome, thank you! – Gawain Sep 21 '13 at 11:47

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.