apply_filters( 'taxonomy_parent_dropdown_args', array $dropdown_args, string $taxonomy, string $context )

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


Parameters

$dropdown_args array
An array of taxonomy parent drop-down arguments.
  • hide_emptyint|bool
    Whether to hide terms not attached to any posts. Default 0|false.
  • hide_if_emptybool
    Whether to hide the drop-down if no terms exist. Default false.
  • taxonomystring
    The taxonomy slug.
  • namestring
    Value of the name attribute to use for the drop-down select element.
    Default 'parent'.
  • orderbystring
    The field to order by. Default 'name'.
  • hierarchicalbool
    Whether the taxonomy is hierarchical. Default true.
  • show_option_nonestring
    Label to display if there are no terms. Default 'None'.
$taxonomy string
The taxonomy slug.
$context string
Filter context. Accepts 'new' or 'edit'.

Top ↑

Source

File: wp-admin/edit-tags.php. View all references

$dropdown_args = apply_filters( 'taxonomy_parent_dropdown_args', $dropdown_args, $taxonomy, 'new' );

Top ↑

Changelog

Changelog
Version Description
4.2.0 Added $context parameter.
3.7.0 Introduced.

Top ↑

User Contributed Notes

You must log in before being able to contribute a note or feedback.