Filters the list of blocks that can contribute to the excerpt. If a dynamic block is added to this list, it must not generate another excerpt, as this will cause an infinite loop to occur.
$allowed_blocks
Sortie :
@param string[] $allowed_blocks The list of names of allowed blocks.
// Modifier la valeur avec le filtre 'excerpt_allowed_blocks'
add_filter('excerpt_allowed_blocks', 'ma_fonction_filtre', 10, 1);
function ma_fonction_filtre($allowed_blocks) {
// Modifier la valeur
return $allowed_blocks;
}
Chargement des actualités...