Filter hook 'wp_sitemaps_taxonomies'

in WP Core File wp-includes/sitemaps/providers/class-wp-sitemaps-taxonomies.php at line 47

View Source

wp_sitemaps_taxonomies

Filter Hook
Description
Filters the list of taxonomy object subtypes available within the sitemap.

Hook Information

File Location wp-includes/sitemaps/providers/class-wp-sitemaps-taxonomies.php View on GitHub
Hook Type Filter
Line Number 47

Hook Parameters

Type Name Description
WP_Taxonomy[] $taxonomies Array of registered taxonomy objects keyed by their name.

Usage Examples

Basic Usage
<?php
// Hook into wp_sitemaps_taxonomies
add_filter('wp_sitemaps_taxonomies', 'my_custom_filter', 10, 1);

function my_custom_filter($taxonomies) {
    // Your custom filtering logic here
    return $taxonomies;
}

Source Code Context

wp-includes/sitemaps/providers/class-wp-sitemaps-taxonomies.php:47 - How this hook is used in WordPress core
<?php
  42  		 *
  43  		 * @since 5.5.0
  44  		 *
  45  		 * @param WP_Taxonomy[] $taxonomies Array of registered taxonomy objects keyed by their name.
  46  		 */
  47  		return apply_filters( 'wp_sitemaps_taxonomies', $taxonomies );
  48  	}
  49  
  50  	/**
  51  	 * Gets a URL list for a taxonomy sitemap.
  52  	 *

PHP Documentation

<?php
/**
		 * Filters the list of taxonomy object subtypes available within the sitemap.
		 *
		 * @since 5.5.0
		 *
		 * @param WP_Taxonomy[] $taxonomies Array of registered taxonomy objects keyed by their name.
		 */
Quick Info
  • Hook Type: Filter
  • Parameters: 1
  • File: wp-includes/sitemaps/providers/class-wp-sitemaps-taxonomies.php
Related Hooks

Related hooks will be displayed here in future updates.