Filter
rpress_category_dropdown
On this page
Filters the term query arguments used by the add-on group dropdown.
Runs in RPRESS_HTML_Elements::category_dropdown() and the result is passed as the second argument to get_terms() for the addon_category taxonomy (add-on groups). It starts as an empty array.
Parameters#
| Parameter | Type | Description |
|---|---|---|
$args | array | get_terms() arguments, empty by default. |
Return value#
array. Arguments for get_terms().
Example#
function my_category_dropdown_args( $args ) {
$args['hide_empty'] = false;
$args['orderby'] = 'name';
return $args;
}
add_filter( 'rpress_category_dropdown', 'my_category_dropdown_args' );
Source#
Applied in:
includes/class-rpress-html-elements.php(line 315), inRPRESS_HTML_Elements::category_dropdown()
See also#
Was this page helpful?
