apply_filters( ‘post_class_taxonomies’, string[] $taxonomies, int $post_id, string[] $classes, string[] $css_class )

In this article

Filters the taxonomies to generate classes for each individual term.

Description

Default is all public taxonomies registered to the post type.

Parameters

$taxonomiesstring[]
List of all taxonomy names to generate classes for.
$post_idint
The post ID.
$classesstring[]
An array of post class names.
$css_classstring[]
An array of additional class names added to the post.

Source

$taxonomies = apply_filters( 'post_class_taxonomies', $taxonomies, $post->ID, $classes, $css_class );

Changelog

VersionDescription
6.1.0Introduced.

User Contributed Notes

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