Type
// Register Custom Taxonomy
function rx_taxonomy() {
$labels = array(
'name' => _x( 'Destinations', 'Taxonomy General Name', 'rixoj' ),
'singular_name' => _x( 'Destination', 'Taxonomy Singular Name', 'rixoj' ),
'menu_name' => __( 'Destination', 'rixoj' ),
'all_items' => __( 'All Destinations', 'rixoj' ),
'parent_item' => __( 'Parent Destination', 'rixoj' ),
'parent_item_colon' => __( 'Parent Destination:', 'rixoj' ),
'new_item_name' => __( 'New Destination Name', 'rixoj' ),
'add_new_item' => __( 'Add New Destination', 'rixoj' ),
'edit_item' => __( 'Edit Destination', 'rixoj' ),
'update_item' => __( 'Update Destination', 'rixoj' ),
'view_item' => __( 'View Destination', 'rixoj' ),
'separate_items_with_commas' => __( 'Separate Destinations with commas', 'rixoj' ),
'add_or_remove_items' => __( 'Add or remove Destinations', 'rixoj' ),
'choose_from_most_used' => __( 'Choose from the most used', 'rixoj' ),
'popular_items' => __( 'Popular Destinations', 'rixoj' ),
'search_items' => __( 'Search Destinations', 'rixoj' ),
'not_found' => __( 'Not Found', 'rixoj' ),
'no_terms' => __( 'No Destinations', 'rixoj' ),
'items_list' => __( 'Destinations list', 'rixoj' ),
'items_list_navigation' => __( 'Destinations list navigation', 'rixoj' ),
);
$rewrite = array(
'slug' => 'holiday-destination',
'with_front' => false,
'hierarchical' => true,
);
$args = array(
'labels' => $labels,
'hierarchical' => true,
'public' => true,
'show_ui' => true,
'show_admin_column' => true,
'show_in_nav_menus' => true,
'show_tagcloud' => false,
'rewrite' => $rewrite,
'show_in_rest' => true,
);
register_taxonomy( 'destination', array( 'tour' ), $args );
}
add_action( 'init', 'rx_taxonomy', 0 );