WordPress at Your Fingertips
filter is not described

category_list_link_attributes filter-hook . WP 5.2.0

Filters the HTML attributes applied to a category list item's anchor element.


add_filter( 'category_list_link_attributes', 'filter_function_name_8511', 10, 5 );
function filter_function_name_8511( $atts, $category, $depth, $args, $id ){
	// filter...

	return $atts;

The HTML attributes applied to the list item's <a> element, empty strings are ignored.

  • href(string)
    The href attribute.

  • title(string)
    The title attribute.
Term data object.
Depth of category, used for padding.
An array of arguments.
ID of the current category.


Since 5.2.0 Introduced.

Where the hook is called

wp-includes/class-walker-category.php 138
$atts = apply_filters( 'category_list_link_attributes', $atts, $category, $depth, $args, $id );

Where in WP core the hook is used WordPress

Usage not found.