[ad_1]
Hi,
How can I category box or meta box on this section
Reference: https://www.awesomescreenshot.com/image/36880635?key=ac88146dfe5f5d67bac1df8f9e7ebfc3
I already have a code added in my custom post type also appears in the dashboard admin.
Reference:https://www.awesomescreenshot.com/image/36880422?key=a574e66a7d830e33a0f55f2ac6575f06
My codes:
add_action( 'init', 'create_blog_taxonomies', 0 );
function create_blog_taxonomies() {
$labels = array(
'name' => _x( 'Categories', 'taxonomy general name' ),
'singular_name' => _x( 'Category', 'taxonomy singular name' ),
'search_items' => __( 'Search Categories' ),
'all_items' => __( 'All Categories' ),
'parent_item' => __( 'Parent Category' ),
'parent_item_colon' => __( 'Parent Category:' ),
'edit_item' => __( 'Edit Category' ),
'update_item' => __( 'Update Category' ),
'add_new_item' => __( 'Add New Category' ),
'new_item_name' => __( 'New Category Name' ),
'menu_name' => __( 'Categories' ),
);
$args = array(
'hierarchical' => true, // Set this to 'false' for non-hierarchical taxonomy (like tags)
'labels' => $labels,
'show_ui' => true,
'show_admin_column' => true,
'query_var' => true,
'show_in_quick_edit' => false,
'rewrite' => array( 'slug' => __( 'blog-category', 'blog' ) ),
);
register_taxonomy( 'blog-category', array( 'blog' ), $args );
}
That codes work with my custom post type however the box or meta box where I can add a category in a post not showing on adding a post like this
Reference:
Thanks in advance!
