bakon machinetype taxonomy
if ( ! function_exists( 'custom_taxonomy_machinetype' ) ) {
// Register Custom Taxonomy
function custom_taxonomy_machinetype() {
$labels = array(
'name' => _x( 'Machinetypes', 'Taxonomy General Name', 'bakon_lang' ),
'singular_name' => _x( 'Machinetype', 'Taxonomy Singular Name', 'bakon_lang' ),
'menu_name' => __( 'Machinetypes', 'bakon_lang' ),
'all_items' => __( 'All Machinetypes', 'bakon_lang' ),
'parent_item' => __( 'Parent Machinetype', 'bakon_lang' ),
'parent_item_colon' => __( 'Parent Machinetype:', 'bakon_lang' ),
'new_item_name' => __( 'New Machinetype Name', 'bakon_lang' ),
'add_new_item' => __( 'Add New Machinetype', 'bakon_lang' ),
'edit_item' => __( 'Edit Machinetype', 'bakon_lang' ),
'update_item' => __( 'Update Machinetype', 'bakon_lang' ),
'separate_items_with_commas' => __( 'Separate Machinetypes with commas', 'bakon_lang' ),
'search_items' => __( 'Search Machinetypes', 'bakon_lang' ),
'add_or_remove_items' => __( 'Add or remove Machinetypes', 'bakon_lang' ),
'choose_from_most_used' => __( 'Choose from the most used Machinetypes', 'bakon_lang' ),
'not_found' => __( 'Not Found', 'bakon_lang' ),
);
$rewrite = array(
'slug' => '',
'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' => true,
'rewrite' => $rewrite,
);
register_taxonomy( 'machinetype', array( 'machine' ), $args );
}
// Hook into the 'init' action
add_action( 'init', 'custom_taxonomy_machinetype', 0 );
}