wp_embed_excerpt_more()WP 4.4.0

Filters the string in the 'more' link displayed after a trimmed excerpt.

Replaces '[...]' (appended to automatically generated excerpts) with an ellipsis and a "Continue reading" link in the embed template.

Хуков нет.

Возвращает

Строку. 'Continue reading' link prepended with an ellipsis.

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

wp_embed_excerpt_more( $more_string );
$more_string(строка) (обязательный)
Default 'more' string.

Список изменений

С версии 4.4.0 Введена.

Код wp_embed_excerpt_more() WP 6.5.2

function wp_embed_excerpt_more( $more_string ) {
	if ( ! is_embed() ) {
		return $more_string;
	}

	$link = sprintf(
		'<a href="%1$s" class="wp-embed-more" target="_top">%2$s</a>',
		esc_url( get_permalink() ),
		/* translators: %s: Post title. */
		sprintf( __( 'Continue reading %s' ), '<span class="screen-reader-text">' . get_the_title() . '</span>' )
	);
	return ' &hellip; ' . $link;
}