Support

Account

Home Forums Backend Issues (wp-admin) Options Page under group of Custom Post Types

Unread

Options Page under group of Custom Post Types

  • We have a menu item added using add_menu_page as a navigation holder for several custom post types:

    function change_management_admin_menu() {
    
        add_menu_page(
            'Change Management',
            'Change Management',
            'read',
            'change-management',
            '',
            'dashicons-randomize',
            6
        );
    
     }

    Each custom post type has 'show_in_menu' => 'change-management' set so it lives under the Change Management admin menu. I’l like to add another menu item to this that is just tied to a few ACF fields. I was thinking I could do this with an ACF options page but for what ever reason, the slug for the main “Change Management” menu item is not change-management, it’s the first post type within that menu, so setting the parent argument is not working.

     if( function_exists('acf_add_options_page') ) {
    
     	acf_add_options_page(array(
     		'page_title' 	=> 'Optimal Blue',
     		'menu_title'	=> 'Optimal Blue',
        'parent'     => 'edit.php?post_type=change-management'
     	));
Viewing 1 post (of 1 total)

The topic ‘Options Page under group of Custom Post Types’ is closed to new replies.