CoreFiles by mySites.guru
excerpt-audio.php23 lines, 630 bytes, from wordpress-5.6.zip
Raw History Compare with 5.5.25
md5
2fd074f5be2c3f83f6cbd7505c1f9072
sha1
2b6114bb85b75a60aea1dfe69bb223f00e1b0d80
sha256
e3dad8d2beac20859b6ef44661b16997a10f6b1cc2aa1e9c6481973ebf806a5e
<?php
/**
 * Show the appropriate content for the Audio post format.
 *
 * @link https://developer.wordpress.org/themes/basics/template-hierarchy/
 *
 * @package WordPress
 * @subpackage Twenty_Twenty_One
 * @since 1.0.0
 */

$content = get_the_content();

if ( has_block( 'core/audio', $content ) ) {
	twenty_twenty_one_print_first_instance_of_block( 'core/audio', $content );
} elseif ( has_block( 'core/embed', $content ) ) {
	twenty_twenty_one_print_first_instance_of_block( 'core/embed', $content );
} else {
	twenty_twenty_one_print_first_instance_of_block( 'core-embed/*', $content );
}

// Add the excerpt.
the_excerpt();

The same content is in 10 releases, WordPress 5.6-beta1 to 5.6. See them all, or every version of this file.