WPSEO_Rank::get_drop_down_readability_labels()publicYoast 1.0

Gets the drop down labels for the readability score.

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

Хуков нет.

Возвращает

Строку. The readability rank label.

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

$WPSEO_Rank = new WPSEO_Rank();
$WPSEO_Rank->get_drop_down_readability_labels();

Код WPSEO_Rank::get_drop_down_readability_labels() Yoast 22.4

public function get_drop_down_readability_labels() {
	$labels = [
		self::BAD => sprintf(
			/* translators: %s expands to the readability score */
			__( 'Readability: %s', 'wordpress-seo' ),
			__( 'Needs improvement', 'wordpress-seo' )
		),
		self::OK => sprintf(
			/* translators: %s expands to the readability score */
			__( 'Readability: %s', 'wordpress-seo' ),
			__( 'OK', 'wordpress-seo' )
		),
		self::GOOD => sprintf(
			/* translators: %s expands to the readability score */
			__( 'Readability: %s', 'wordpress-seo' ),
			__( 'Good', 'wordpress-seo' )
		),
	];

	return $labels[ $this->rank ];
}