WP HOOKS
filtrod 6.5.0

get_block_type_uses_context

Args 2Plik wp-includes/class-wp-block-type.phpDokumentacja WP ↗

Opis — z kodu źródłowego

Filters the registered uses context for a block type.

Parametry

ParametrTypOpis
$uses_contextstring[]Array of registered uses context for a block type.
$block_type\WP_Block_TypeThe 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
}

Popularne w tej kategorii