wpseo_indexable_excluded_taxonomies
Filter: wpseo_indexable_excluded_taxonomies Allow developers to prevent a certain taxonomy from being saved to the indexable table.
Использование
add_filter( 'wpseo_indexable_excluded_taxonomies', 'wp_kama_wpseo_indexable_excluded_taxonomies_filter' ); /** * Function for `wpseo_indexable_excluded_taxonomies` filter-hook. * * @param array $excluded_taxonomies The currently excluded taxonomies. * * @return array */ function wp_kama_wpseo_indexable_excluded_taxonomies_filter( $excluded_taxonomies ){ // filter... return $excluded_taxonomies; }
- $excluded_taxonomies(массив)
- The currently excluded taxonomies.
Где вызывается хук
wpseo_indexable_excluded_taxonomies
yoast/src/helpers/taxonomy-helper.php 131
$excluded_taxonomies = \apply_filters( 'wpseo_indexable_excluded_taxonomies', [] );