filtrod 5.8.0
widget_block_dynamic_classname
Opis — z kodu źródłowego
The classname used in the block widget's container HTML.
This can be set according to the name of the block contained by the block widget.
Parametry
| Parametr | Typ | Opis |
|---|---|---|
$classname | string | The classname to be used in the block widget's container HTML, e.g. 'widget_block widget_text'. |
$block_name | string | The name of the block contained by the block widget, e.g. 'core/paragraph'. |
Wywołanie
Rejestracja callbackaphp
// rejestracja funkcji zwrotnej — podaj liczbę argumentów!
add_filter( 'widget_block_dynamic_classname', 'twoja_funkcja', 10, 2 );
function twoja_funkcja($param_1, $param_2) {
// Twój kod
}
// rejestracja funkcji zwrotnej — podaj liczbę argumentów!
add_filter( 'widget_block_dynamic_classname', 'twoja_funkcja', 10, 2 );
function twoja_funkcja($param_1, $param_2) {
// Twój kod
}Popularne w tej kategorii