<?php

/**
 * Custom taxonomies
 * @see codex.wordpress.org/Function_Reference/register_taxonomy
 * @category Functions
 * @author Krik
 */

// Genres@Book taxonomy
// add_action('init', 'krik_genres_taxonomy');

function krik_genres_taxonomy()
{
	$labels = array(
		'name' => __('Genres', 'krik'),
		'singular_name' => __('Genre', 'krik'),
		'search_items' => __('Search Genres', 'krik'),
		'all_items' => __('All Genres', 'krik'),
		'parent_item' => __('Parent Genre', 'krik'),
		'parent_item_colon' => __('Parent Genre:', 'krik'),
		'edit_item' => __('Edit Genre', 'krik'),
		'update_item' => __('Update Genre', 'krik'),
		'add_new_item' => __('Add New Genre', 'krik'),
		'new_item_name' => __('New Genre Name', 'krik'),
		'menu_name' => __('Genre', 'krik'),
	);
	$args = array(
		'hierarchical' => true,
		'labels' => $labels,
		'show_ui' => true,
		'show_admin_column' => true,
		'query_var' => true,
		'rewrite' => array('slug' => 'genre'),
	);
	register_taxonomy('genre', 'book', $args);
}
