wpseo_opengraph_show_publish_date хук-фильтр . Yoast 1.0
Filter: 'wpseo_opengraph_show_publish_date' - Allow showing publication date for other post types.
Использование
add_filter( 'wpseo_opengraph_show_publish_date', 'filter_function_name_5850', 10, 2 ); function filter_function_name_5850( $post_type, $post_post_type ){ // filter... return $post_type; }
- $post_type(строка)
- The current URL's post type.
- $post_post_type(true/false)
- Whether or not to show publish date.
Где вызывается хук
wpseo_opengraph_show_publish_date
yoast/src/presentations/indexable-post-type-presentation.php 269
if ( ! \apply_filters( 'wpseo_opengraph_show_publish_date', false, $this->post->get_post_type( $this->source ) ) ) {