if ( ! function_exists( 'faq_taxonomy' ) ) { // Register Custom Taxonomy function faq_taxonomy() { $labels = array( 'name' => _x( 'Categoría', 'Taxonomy General Name', 'cat_preguntas' ), 'singular_name' => _x( 'Categorias', 'Taxonomy Singular Name', 'cat_preguntas' ), 'menu_name' => __( 'Categorías', 'cat_preguntas' ), 'all_items' => __( 'Todas las categorías', 'cat_preguntas' ), 'parent_item' => __( 'Categoría padre', 'cat_preguntas' ), 'parent_item_colon' => __( 'Categoría padre:', 'cat_preguntas' ), 'new_item_name' => __( 'Nuevo nombre de categoría', 'cat_preguntas' ), 'add_new_item' => __( 'Agregar nueva categoría', 'cat_preguntas' ), 'edit_item' => __( 'Editar categoría', 'cat_preguntas' ), 'update_item' => __( 'Actualizar categoría', 'cat_preguntas' ), 'view_item' => __( 'Ver categoría', 'cat_preguntas' ), 'separate_items_with_commas' => __( 'Separar categorías por comas', 'cat_preguntas' ), 'add_or_remove_items' => __( 'Agregar o remover categorías', 'cat_preguntas' ), 'choose_from_most_used' => __( 'Elegir la mas usada', 'cat_preguntas' ), 'popular_items' => __( 'Categorías populares', 'cat_preguntas' ), 'search_items' => __( 'Buscar categorías', 'cat_preguntas' ), 'not_found' => __( 'No encontrado', 'cat_preguntas' ), 'no_terms' => __( 'Sin categorías', 'cat_preguntas' ), 'items_list' => __( 'Lista de categorías', 'cat_preguntas' ), 'items_list_navigation' => __( 'Navegación de lista de categorías', 'cat_preguntas' ), ); $rewrite = array( 'slug' => 'categoria_pregunta', 'with_front' => true, '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, ); register_taxonomy( 'preguntas_taxonomy', array( 'preguntas' ), $args ); } add_action( 'init', 'faq_taxonomy', 0 ); }