Or, embed this snippet using GenerateWP WordPress Plugin.

Download

Clone

RA – Domain Taxonomy

Kin.

// Register Custom Taxonomy
function register_domaines_taxonomy() {

	$labels = array(
		'name'                       => _x( 'Domains', 'Taxonomy General Name', 'ra' ),
		'singular_name'              => _x( 'Domain', 'Taxonomy Singular Name', 'ra' ),
		'menu_name'                  => __( 'Domains', 'ra' ),
		'all_items'                  => __( 'All Domains', 'ra' ),
		'parent_item'                => __( 'Parent Domain', 'ra' ),
		'parent_item_colon'          => __( 'Parent Domain:', 'ra' ),
		'new_item_name'              => __( 'New Domain Name', 'ra' ),
		'add_new_item'               => __( 'Add New Domain', 'ra' ),
		'edit_item'                  => __( 'Edit Domain', 'ra' ),
		'update_item'                => __( 'Update Domain', 'ra' ),
		'view_item'                  => __( 'View Domain', 'ra' ),
		'separate_items_with_commas' => __( 'Separate domains with commas', 'ra' ),
		'add_or_remove_items'        => __( 'Add or remove domains', 'ra' ),
		'choose_from_most_used'      => __( 'Choose the most used domain', 'ra' ),
		'popular_items'              => __( 'Popular Domains', 'ra' ),
		'search_items'               => __( 'Search Domains', 'ra' ),
		'not_found'                  => __( 'Not Found', 'ra' ),
	);
	$args = array(
		'labels'                     => $labels,
		'hierarchical'               => true,
		'public'                     => true,
		'show_ui'                    => true,
		'show_admin_column'          => true,
		'show_in_nav_menus'          => false,
		'show_tagcloud'              => false,
	);
	register_taxonomy( 'domain', array( 'service', 'realisation' ), $args );

}

// Hook into the 'init' action
add_action( 'init', 'register_domaines_taxonomy', 0 );