All features

Cherry Blossom feature

Content types Taxonomies: Taxonomy

Represents a WordPress taxonomy definition.

Represents a WordPress taxonomy definition.

Capabilities and extension points

Additional post types associated by registration controllers.

  • var array

Gets the immutable taxonomy definition family.

  • return string Definition family.

Registers required taxonomy hooks.

Registers the taxonomy with WordPress.

  • return \WP_Taxonomy|\WP_Error Registered taxonomy or error.

Gets arguments passed to register_taxonomy().

  • return array Taxonomy registration arguments.

Gets default taxonomy arguments.

  • return array Default registration arguments.

Gets the complete taxonomy label set.

  • return array Taxonomy labels.

Adds post type associations discovered by registration controllers.

  • param array|string $object_types Post type identifiers.

Gets associated post type identifiers.

  • return array Post type identifiers.

Explicitly links the taxonomy to its post types.

Validates the taxonomy definition.

  • return true|\WP_Error True when valid, otherwise an error.

Source reference

This editable reference page is based on the PHP documentation in content-types/taxonomies/class-taxonomy.php.