WP HOOKS
filtrod 3.7.0

taxonomy_parent_dropdown_args

Args 3Plik wp-admin/edit-tags.phpDokumentacja WP ↗

Opis — z kodu źródłowego

Filters the taxonomy parent drop-down on the Edit Term page.

Parametry

ParametrTypOpis
$dropdown_argsarray{ An array of taxonomy parent drop-down arguments. @type int|bool $hide_empty Whether to hide terms not attached to any posts. Default 0. @type bool $hide_if_empty Whether to hide the drop-down if no terms exist. Default false. @type string $taxonomy The taxonomy slug. @type string $name Value of the name attribute to use for the drop-down select element. Default 'parent'. @type string $orderby The field to order by. Default 'name'. @type bool $hierarchical Whether the taxonomy is hierarchical. Default true. @type string $show_option_none Label to display if there are no terms. Default 'None'. }
$taxonomystringThe taxonomy slug.
$contextstringFilter context. Accepts 'new' or 'edit'.

Wywołanie

Rejestracja callbackaphp
// rejestracja funkcji zwrotnej — podaj liczbę argumentów!
add_filter( 'taxonomy_parent_dropdown_args', 'twoja_funkcja', 10, 3 );

function twoja_funkcja($param_1, $param_2, $param_3) {
	// Twój kod
}

Popularne w tej kategorii