register_taxonomy(‘new-id’,’posttype-id’,[
‘public’ => true,
]);
register_taxonomy(‘new-id2′,’posttype-id’,[
‘public’ => true,
‘hierarchical’ => true
]);
register_taxonomy('new-id','posttype-id',[ 'public' => true, ]); register_taxonomy('new-id2','posttype-id',[ 'public' => true, 'hierarchical' => true ]);
Display the taxonomy
if(get_the_terms( get_the_id(), 'taxonomoy_id' )): $variable = get_the_terms( get_the_id(), 'taxonomoy_id' ); echo $variable[0]->name; endif;