/path>'; } else { $markup .= '' . $title . ''; } if ( isset( $page['children'] ) ) { if ( $is_navigation_child && $show_submenu_icons && ! $open_submenus_on_click ) { $markup .= ''; } $markup .= ''; } $markup .= ''; } return $markup; } /** * Outputs nested array of pages * * @param array $current_level The level being iterated through. * @param array $children The children grouped by parent post ID. * * @return array The nested array of pages. */ function block_core_page_list_nest_pages( $current_level, $children ) { if ( empty( $current_level ) ) { return; } foreach ( (array) $current_level as $key => $current ) { if ( isset( $children[ $key ] ) ) { $current_level[ $key ]['children'] = block_core_page_list_nest_pages( $children[ $key ], $children ); } } return $current_level; } /** * Renders the `core/page-list` block on server. * * @param array $attributes The block attributes. * @param string $content The saved content. * @param WP_Block $block The parsed block. * * @return string Returns the page list markup. */ function render_block_core_page_list( $attributes, $content, $block ) { static $block_id = 0; ++$block_id; $parent_page_id = $attributes['parentPageID']; $is_nested = $attributes['isNested']; $all_pages = get_pages( array( 'sort_column' => 'menu_order,post_title', 'order' => 'asc', ) ); // If there are no pages, there is nothing to show. if ( empty( $all_pages ) ) { return; } $top_level_pages = array(); $pages_with_children = array(); $active_page_ancestor_ids = array(); foreach ( (array) $all_pages as $page ) { $is_active = ! empty( $page->ID ) && ( get_queried_object_id() === $page->I
Deprecated: trim(): Passing null to parameter #1 ($string) of type string is deprecated in /data/sites/web/cerbonecostruzionicom/www/wp-content/themes/betheme/functions/theme-functions.php on line 131

Warning: Cannot modify header information - headers already sent by (output started at /data/sites/web/cerbonecostruzionicom/www/wp-includes/blocks/page-list.php:1) in /data/sites/web/cerbonecostruzionicom/www/wp-includes/pluggable.php on line 1427

Warning: Cannot modify header information - headers already sent by (output started at /data/sites/web/cerbonecostruzionicom/www/wp-includes/blocks/page-list.php:1) in /data/sites/web/cerbonecostruzionicom/www/wp-includes/pluggable.php on line 1430