wpseo_opengraph_site_name
Filter: wpseo_opengraph_site_name Allow changing the Yoast SEO generated Open Graph site name.
Использование
add_filter( 'wpseo_opengraph_site_name', 'wp_kama_wpseo_opengraph_site_name_filter', 10, 2 ); /** * Function for `wpseo_opengraph_site_name` filter-hook. * * @param string $site_name The site_name. * @param Indexable_Presentation $presentation The presentation of an indexable. * * @return string */ function wp_kama_wpseo_opengraph_site_name_filter( $site_name, $presentation ){ // filter... return $site_name; }
- $site_name(строка)
- The site_name.
- $presentation(Indexable_Presentation)
- The presentation of an indexable.
Где вызывается хук
wpseo_opengraph_site_name
yoast/src/presenters/open-graph/site-name-presenter.php 39
return (string) \trim( \apply_filters( 'wpseo_opengraph_site_name', $this->presentation->open_graph_site_name, $this->presentation ) );