I have registered a custom post type oa_location with custom menu (using show_in_menu) and a taxonomy called oa_country. These two connected but because our CPT placed in a custom menu, there is a problem in url of taxonomy term:
http://localhost/demo/wp-admin/term.php?taxonomy=oa_country&tag_ID=46&post_type=post&wp_http_referer=demo/wp-admin/edit-tags.php?taxonomy=oa_country
my code to register this CPT:
$arg = array(
'label' => __('Post Type', 'text_domain'),
'description' => __('Post Type Description', 'text_domain'),
'labels' => $labels,
'show_in_menu' => 'our-agencies',
'taxonomies' => array('oa_country'),
);
register_post_type('oa_location');
the problem is about show_in_menu. what can i do?