registered_taxonomy is a hook triggered after a custom taxonomy has been registered. This hook provides the taxonomy key, the name of the object type for the taxonomy object and arguments used to register the taxonomy as parameters.
<?php add_action( 'registered_taxonomy', 'function_name' ); ?>
where "function_name" is the name of the function to be called.
/** * Example of registered_taxonomy usage * @param string $taxonomy Taxonomy key. * @param array|string $object_type Name of the object type for the taxonomy object. * @param array|string $args Optional args used in taxonomy registration. */ function wporg_registered_taxonomy_example( $taxonomy, $object_type, $args ) { if ( 'customtax' == $taxonomy ) { // Do something after customtax is registered as custom taxonomy } } add_action( 'registered_taxonomy', 'wporg_registered_taxonomy_example', 10, 3 );
The registered_taxonomy hook is found in wp-includes/taxonomy.php
within the register_taxonomy() function.