wpseo_typecount_join
Filter JOIN query part for type count of post type.
Использование
add_filter( 'wpseo_typecount_join', 'wp_kama_wpseo_typecount_join_filter', 10, 2 );
/**
* Function for `wpseo_typecount_join` filter-hook.
*
* @param string $join SQL part.
* @param string $post_type Post type name.
*
* @return string
*/
function wp_kama_wpseo_typecount_join_filter( $join, $post_type ){
// filter...
return $join;
}
- $join(строка)
- SQL part.
По умолчанию: empty string - $post_type(строка)
- Post type name.
Где вызывается хук
wpseo_typecount_join
yoast/inc/sitemaps/class-post-type-sitemap-provider.php 328
$join_filter = apply_filters( 'wpseo_typecount_join', '', $post_type );