wp_sitemaps_taxonomies_query_args filter-hook . WP 5.5.0
Filters the taxonomy terms query arguments.
Allows modification of the taxonomy query arguments before querying.
Usage
add_filter( 'wp_sitemaps_taxonomies_query_args', 'filter_function_name_1209', 10, 2 ); function filter_function_name_1209( $args, $taxonomy ){ // filter... return $args; }
- $args(array)
- Array of WP_Term_Query arguments.
- $taxonomy(string)
- Taxonomy name.
Changelog
Since 5.5.0 | Introduced. |
Where the hook is called
wp_sitemaps_taxonomies_query_args
wp-includes/sitemaps/providers/class-wp-sitemaps-taxonomies.php 185-197
$args = apply_filters( 'wp_sitemaps_taxonomies_query_args', array( 'fields' => 'ids', 'taxonomy' => $taxonomy, 'orderby' => 'term_order', 'number' => wp_sitemaps_get_max_urls( $this->object_type ), 'hide_empty' => true, 'hierarchical' => false, 'update_term_meta_cache' => false, ), $taxonomy );