WP_Post_Type::register_taxonomies() WordPress Method
The WP_Post_Type::register_taxonomies() method is used to register taxonomies for a post type. This method should be called in the constructor for the post type.
WP_Post_Type::register_taxonomies() #
Registers the taxonomies for the post type.
Source
File: wp-includes/class-wp-post-type.php
public function register_taxonomies() {
foreach ( $this->taxonomies as $taxonomy ) {
register_taxonomy_for_object_type( $taxonomy, $this->name );
}
}
Expand full source codeCollapse full source codeView on TracView on GitHub
Changelog
| Version | Description |
|---|---|
| 4.6.0 | Introduced. |