I’ve been searching for a while for an answer to this, but the results I find always deal with custom post types as opposed to the built-in ‘post’ post type.
I want to remove the default ‘Post Tags’ taxonomy from the built-in ‘post’ post type and then add my own custom taxonomy to replace it. Essentially, I have other custom post types using my custom taxonomy and I’d like to align the ‘post’ post type with them.
I can’t for the life of me figure out how to edit the default post type though, any ideas how I would do this?
Thanks in advance.
1 Answer
to completely remove post tags: https://stackoverflow.com/a/8363082
if you want to remove post tags from posts, but keep on other custom post types:
add_action( 'init', 'my_register_post_tags' );
function my_register_post_tags() {
register_taxonomy( 'post_tag', array( 'my_post_type_here' ) );
}
to add your own custom taxonomy to posts, use register_taxonomy, setting the $object_type
parameter to post
.