Yoast\WP\SEO\Surfaces

Meta_Surface::for_search_result()publicYoast 1.0

Returns the meta tags context for the search result page.

Метод класса: Meta_Surface{}

Хуков нет.

Возвращает

Meta|false. The meta values. False if none could be found.

Использование

$Meta_Surface = new Meta_Surface();
$Meta_Surface->for_search_result();

Код Meta_Surface::for_search_result() Yoast 19.10

public function for_search_result() {
	$indexable = $this->repository->find_for_system_page( 'search-result' );

	if ( ! $indexable ) {
		return false;
	}

	return $this->build_meta( $this->context_memoizer->get( $indexable, 'Search_Result_Page' ) );
}