filtrod 6.5.0
get_block_type_uses_context
Opis — z kodu źródłowego
Filters the registered uses context for a block type.
Parametry
| Parametr | Typ | Opis |
|---|---|---|
$uses_context | string[] | Array of registered uses context for a block type. |
$block_type | \WP_Block_Type | The full block type object. |
Wywołanie
Rejestracja callbackaphp
// rejestracja funkcji zwrotnej — podaj liczbę argumentów!
add_filter( 'get_block_type_uses_context', 'twoja_funkcja', 10, 2 );
function twoja_funkcja($param_1, $param_2) {
// Twój kod
}
// rejestracja funkcji zwrotnej — podaj liczbę argumentów!
add_filter( 'get_block_type_uses_context', 'twoja_funkcja', 10, 2 );
function twoja_funkcja($param_1, $param_2) {
// Twój kod
}Popularne w tej kategorii