Changeset 56065 for trunk/src/wp-includes/blocks/page-list.php
- Timestamp:
- 06/27/2023 02:20:18 PM (3 years ago)
- File:
-
- 1 edited
-
trunk/src/wp-includes/blocks/page-list.php (modified) (4 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/blocks/page-list.php
r55246 r56065 151 151 return; 152 152 } 153 $markup = ''; 153 $front_page_id = (int) get_option( 'page_on_front' ); 154 $markup = ''; 154 155 foreach ( (array) $nested_pages as $page ) { 155 156 $css_class = $page['is_active'] ? ' current-menu-item' : ''; … … 182 183 } 183 184 184 $front_page_id = (int) get_option( 'page_on_front' );185 185 if ( (int) $page['page_id'] === $front_page_id ) { 186 186 $css_class .= ' menu-item-home'; … … 283 283 'page_id' => $page->ID, 284 284 'title' => $page->post_title, 285 'link' => get_permalink( $page ->ID),285 'link' => get_permalink( $page ), 286 286 'is_active' => $is_active, 287 287 ); … … 290 290 'page_id' => $page->ID, 291 291 'title' => $page->post_title, 292 'link' => get_permalink( $page ->ID),292 'link' => get_permalink( $page ), 293 293 'is_active' => $is_active, 294 294 );
Note: See TracChangeset
for help on using the changeset viewer.