Filters the list of CSS classes to include with each page item in the list.
$css_classstring[]$pageWP_Post$depthint$argsarray$current_page_idintwp-content/themes/twentytwenty/classes/class-twentytwenty-walker-page.php:71TwentyTwenty_Walker_Page::start_el()wp-includes/class-walker-page.php:159Walker_Page::start_el() * @param string[] $css_class An array of CSS classes to be applied to each list item. * @param WP_Post $page Page data object. * @param int $depth Depth of page, used for padding. * @param array $args An array of arguments. * @param int $current_page_id ID of the current page. */ $css_classes = implode( ' ', apply_filters( 'page_css_class', $css_class, $page, $depth, $args, $current_page_id ) ); $css_classes = $css_classes ? ' class="' . esc_attr( $css_classes ) . '"' : ''; if ( '' === $page->post_title ) { /* translators: %d: ID of a post. */ $page->post_title = sprintf( __( '#%d (no title)' ), $page->ID ); }Introduced in 2.8.0. Unchanged from 6.7.7 through 7.1.0.
Signature, return type and hooks compared across 5 parsed releases.