WP_Post_Type::unregister_taxonomies() WordPress Method

The WP_Post_Type::unregister_taxonomies() function can be used to unregister taxonomies for a post type. This function takes a single argument, the post type for which you want to unregister the taxonomies.

WP_Post_Type::unregister_taxonomies() #

Removes the post type from all taxonomies.


Source

File: wp-includes/class-wp-post-type.php

	public function unregister_taxonomies() {
		foreach ( get_object_taxonomies( $this->name ) as $taxonomy ) {
			unregister_taxonomy_for_object_type( $taxonomy, $this->name );
		}
	}


Top ↑

Changelog

Changelog
VersionDescription
4.6.0Introduced.

The content displayed on this page has been created in part by processing WordPress source code files which are made available under the GPLv2 (or a later version) license by theĀ Free Software Foundation. In addition to this, the content includes user-written examples and information. All material is subject to review and curation by the WPPaste.com community.