wpseo_twitter_title
Filter: wpseo_twitter_title Allow changing the Twitter title.
Использование
add_filter( 'wpseo_twitter_title', 'wp_kama_wpseo_twitter_title_filter', 10, 2 ); /** * Function for `wpseo_twitter_title` filter-hook. * * @param string $twitter_title The Twitter title. * @param Indexable_Presentation $presentation The presentation of an indexable. * * @return string */ function wp_kama_wpseo_twitter_title_filter( $twitter_title, $presentation ){ // filter... return $twitter_title; }
- $twitter_title(строка)
- The Twitter title.
- $presentation(Indexable_Presentation)
- The presentation of an indexable.
Где вызывается хук
yoast/src/presenters/twitter/title-presenter.php 32
return \trim( \apply_filters( 'wpseo_twitter_title', $this->replace_vars( $this->presentation->twitter_title ), $this->presentation ) );