'fcn_chapter' ) ); ?>
post_password ) ? 'password' : ''; $title = fictioneer_get_safe_title( get_the_ID() ); $this_breadcrumb = [$title, get_the_permalink()]; // Story data if ( $story_post ) { $story_data = fictioneer_get_story_data( $story_id ); $chapter_ids = $story_data['chapter_ids']; } // Chapter navigation $current_index = array_search( get_the_ID(), $chapter_ids ); $prev_index = $current_index - 1; $next_index = $current_index + 1; // Arguments for hooks and templates/etc. and includes $hook_args = array( 'author' => get_userdata( $post->post_author ), 'story_post' => $story_post, 'story_data' => $story_data, 'chapter_id' => get_the_ID(), 'chapter_title' => $title, 'chapter_password' => $post->post_password, 'chapter_ids' => $chapter_ids, 'current_index' => $current_index, 'prev_index' => $prev_index >= 0 ? $prev_index : false, 'next_index' => isset( $chapter_ids[$next_index] ) ? $next_index : false ); ?>
'fcn_chapter', 'post_id' => get_the_ID(), 'breadcrumbs' => array( [fcntr( 'frontpage' ), get_home_url()] ) ); // Add stories list breadcrumb (if set) $stories_page = intval( get_option( 'fictioneer_stories_page', -1 ) ); if ( $stories_page > 0 ) { $stories_page_title = trim( get_the_title( $stories_page ) ); $stories_page_title = empty( $stories_page_title ) ? __( 'Stories', 'fictioneer' ) : $stories_page_title; $footer_args['breadcrumbs'][] = array( $stories_page_title, get_permalink( $stories_page ) ); } // Add story (if set) if ( $story_post ) { $footer_args['breadcrumbs'][] = array( $story_data['title'], get_the_permalink( $story_id ) ); } // Add current breadcrumb $footer_args['breadcrumbs'][] = $this_breadcrumb; // Get footer with breadcrumbs get_footer( null, $footer_args ); ?>