wpseek.com
Outil de recherche WordPress pour les développeurs et auteurs de thèmes



wp_embed_excerpt_attachment › WordPress Function

Depuis4.4.0
Dépréciéen/a
wp_embed_excerpt_attachment ( $content )
Paramètres:
  • (string) $content The current post excerpt.
    Requis: Oui
Retourne:
  • (string) The modified post excerpt.
Défini(e) dans:
Codex:

Filters the post excerpt for the embed template.

Shows players for video and audio attachments.


Source

function wp_embed_excerpt_attachment( $content ) {
	if ( is_attachment() ) {
		return prepend_attachment( '' );
	}

	return $content;
}