Or, embed this snippet using GenerateWP WordPress Plugin.

Download

Clone

Equipment Manufacturers

// Register Custom Taxonomy
function rpls_register_tax_equipment_manufacturers() {

	$labels = array(
		'name'                       => _x( 'Manufacturers', 'Taxonomy General Name', 'rpls_equipment_manufacturers' ),
		'singular_name'              => _x( 'Manufacturer', 'Taxonomy Singular Name', 'rpls_equipment_manufacturers' ),
		'menu_name'                  => __( 'Manufacturers', 'rpls_equipment_manufacturers' ),
		'all_items'                  => __( 'All Manufacturers', 'rpls_equipment_manufacturers' ),
		'parent_item'                => __( 'Parent Manufacturer', 'rpls_equipment_manufacturers' ),
		'parent_item_colon'          => __( 'Parent Manufacturer:', 'rpls_equipment_manufacturers' ),
		'new_item_name'              => __( 'New Manufacturer Name', 'rpls_equipment_manufacturers' ),
		'add_new_item'               => __( 'Add New Manufacturer', 'rpls_equipment_manufacturers' ),
		'edit_item'                  => __( 'Edit Manufacturer', 'rpls_equipment_manufacturers' ),
		'update_item'                => __( 'Update Manufacturer', 'rpls_equipment_manufacturers' ),
		'view_item'                  => __( 'View Manufacturer', 'rpls_equipment_manufacturers' ),
		'separate_items_with_commas' => __( 'Separate Manufacturers with commas', 'rpls_equipment_manufacturers' ),
		'add_or_remove_items'        => __( 'Add or remove Manufacturers', 'rpls_equipment_manufacturers' ),
		'choose_from_most_used'      => __( 'Choose from the most used', 'rpls_equipment_manufacturers' ),
		'popular_items'              => __( 'Popular Manufacturers', 'rpls_equipment_manufacturers' ),
		'search_items'               => __( 'Search Manufacturers', 'rpls_equipment_manufacturers' ),
		'not_found'                  => __( 'Not Found', 'rpls_equipment_manufacturers' ),
		'no_terms'                   => __( 'No Manufacturers', 'rpls_equipment_manufacturers' ),
		'items_list'                 => __( 'Manufacturers list', 'rpls_equipment_manufacturers' ),
		'items_list_navigation'      => __( 'Manufacturers list navigation', 'rpls_equipment_manufacturers' ),
	);
	$rewrite = array(
		'slug'                       => 'manufacturer',
		'with_front'                 => true,
		'hierarchical'               => false,
	);
	$args = array(
		'labels'                     => $labels,
		'hierarchical'               => true,
		'public'                     => true,
		'show_ui'                    => true,
		'show_admin_column'          => true,
		'show_in_nav_menus'          => true,
		'show_tagcloud'              => true,
		'query_var'                  => 'manufacturers',
		'rewrite'                    => $rewrite,
		'show_in_rest'               => true,
	);
	register_taxonomy( 'equipment_manufacturers', array( 'equipment_registry' ), $args );

}
add_action( 'init', 'rpls_register_tax_equipment_manufacturers', 0 );