Filters the list of CSS class names for the current post.
$classesstring[]$css_classstring[]$post_idintwp-includes/post-template.php:607get_post_class() * @since 2.7.0 * * @param string[] $classes An array of post class names. * @param string[] $css_class An array of additional class names added to the post. * @param int $post_id The post ID. */ $classes = apply_filters( 'post_class', $classes, $css_class, $post->ID ); return array_unique( $classes );} /** * Displays the class names for the body element.Introduced in 2.7.0. Unchanged from 6.7.7 through 7.1.0.
Signature, return type and hooks compared across 5 parsed releases.