Yoast\WP\SEO\Abilities\Application

Score_Retriever::get_indexable_titleprivateYoast 1.0

Returns the title for an indexable, with a fallback.

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

Хуков нет.

Возвращает

Строку. The post title.

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

// private - только в коде основоного (родительского) класса
$result = $this->get_indexable_title( $indexable ): string;
$indexable(объект) (обязательный)
The indexable object.

Код Score_Retriever::get_indexable_title() Yoast 27.7

private function get_indexable_title( $indexable ): string {
	if ( ! empty( $indexable->breadcrumb_title ) ) {
		return $indexable->breadcrumb_title;
	}

	return \__( '(no title)', 'wordpress-seo' );
}