hooked_block_types

FILTER wp-includes\blocks.php (ligne 967) github
Filters the list of hooked block types for a given anchor block type and relative position.

Paramètres

Entrée :
$hooked_block_types, $relative_position, $anchor_block_type, $context
Sortie :
@param string[]                        $hooked_block_types The list of hooked block types.
@param string                          $relative_position  The relative position of the hooked blocks.
@param string                          $anchor_block_type  The anchor block type.
@param WP_Block_Template|WP_Post|array $context            The block template, template part, post object,

Utilisation

// Modifier la valeur avec le filtre 'hooked_block_types'
add_filter('hooked_block_types', 'ma_fonction_filtre', 10, 1);

function ma_fonction_filtre($hooked_block_types) {
    // Modifier la valeur
    return $hooked_block_types;
}

Actualités

Chargement des actualités...