wpseo_should_index_links
Filter: wpseo_should_index_links Allows disabling of Yoast's links indexation.
Использование
add_filter( 'wpseo_should_index_links', 'wp_kama_wpseo_should_index_links_filter' ); /** * Function for `wpseo_should_index_links` filter-hook. * * @param bool $enable To disable the indexation, return false. * * @return bool */ function wp_kama_wpseo_should_index_links_filter( $enable ){ // filter... return $enable; }
- $enable(true|false)
- To disable the indexation, return false.
Где вызывается хук
wpseo_should_index_links
yoast/src/conditionals/should-index-links-conditional.php 41
return \apply_filters( 'wpseo_should_index_links', $should_index_links );