2023-01-21 01:31:34 +01:00
|
|
|
<?php
|
|
|
|
/**
|
|
|
|
* Single Post
|
|
|
|
*
|
|
|
|
* @package WordPress
|
|
|
|
* @subpackage Fictioneer
|
|
|
|
* @since 1.0
|
|
|
|
*/
|
|
|
|
|
2023-08-17 16:13:12 +02:00
|
|
|
|
2024-05-10 01:26:09 +02:00
|
|
|
// Setup
|
|
|
|
$password_required = post_password_required();
|
|
|
|
|
2023-08-17 16:13:12 +02:00
|
|
|
// Header
|
|
|
|
get_header();
|
|
|
|
|
|
|
|
?>
|
2023-01-21 01:31:34 +01:00
|
|
|
|
|
|
|
<main id="main" class="main post">
|
2024-04-14 12:57:59 +02:00
|
|
|
|
2023-07-30 17:00:40 +02:00
|
|
|
<div class="observer main-observer"></div>
|
2024-04-14 12:57:59 +02:00
|
|
|
|
2023-01-21 01:31:34 +01:00
|
|
|
<?php do_action( 'fictioneer_main' ); ?>
|
2024-04-14 12:57:59 +02:00
|
|
|
|
2023-01-21 01:31:34 +01:00
|
|
|
<div class="main__wrapper">
|
2024-04-14 12:57:59 +02:00
|
|
|
|
2023-01-21 01:31:34 +01:00
|
|
|
<?php do_action( 'fictioneer_main_wrapper' ); ?>
|
|
|
|
|
|
|
|
<?php while ( have_posts() ) : the_post(); ?>
|
|
|
|
|
|
|
|
<?php
|
|
|
|
// Setup
|
2024-03-01 12:39:42 +01:00
|
|
|
$title = fictioneer_get_safe_title( $post->ID, 'single-post' );
|
2023-12-02 00:00:13 +01:00
|
|
|
$this_breadcrumb = [ $title, get_the_permalink() ];
|
2023-01-21 01:31:34 +01:00
|
|
|
?>
|
|
|
|
|
|
|
|
<article id="post-<?php the_ID(); ?>" class="post__article padding-left padding-right padding-top padding-bottom">
|
|
|
|
|
|
|
|
<header class="post__header">
|
|
|
|
<h1 class="post__title"><?php echo $title; ?></h1>
|
|
|
|
<div class="post__meta layout-links"><?php echo fictioneer_get_post_meta_items(); ?></div>
|
|
|
|
</header>
|
|
|
|
|
|
|
|
<section class="post__main content-section"><?php the_content(); ?></section>
|
|
|
|
|
2023-12-02 00:00:13 +01:00
|
|
|
<?php do_action( 'fictioneer_post_after_content', $post->ID ); ?>
|
2023-01-21 01:31:34 +01:00
|
|
|
|
2024-05-10 01:26:09 +02:00
|
|
|
<?php if ( ! $password_required && ( has_action( 'fictioneer_post_footer_left' ) || has_action( 'fictioneer_post_footer_right' ) ) ) : ?>
|
2023-01-21 01:31:34 +01:00
|
|
|
<footer class="post__footer">
|
2023-08-30 13:51:49 +02:00
|
|
|
<div class="post__footer-box post__footer-left">
|
2023-12-02 00:00:13 +01:00
|
|
|
<?php do_action( 'fictioneer_post_footer_left', $post->ID ); ?>
|
2023-08-30 13:51:49 +02:00
|
|
|
</div>
|
|
|
|
<div class="post__footer-box post__footer-right">
|
2023-12-02 00:00:13 +01:00
|
|
|
<?php do_action( 'fictioneer_post_footer_right', $post->ID ); ?>
|
2023-08-30 13:51:49 +02:00
|
|
|
</div>
|
2023-01-21 01:31:34 +01:00
|
|
|
</footer>
|
|
|
|
<?php endif; ?>
|
|
|
|
|
|
|
|
</article>
|
|
|
|
|
|
|
|
<?php do_action( 'fictioneer_before_comments' ); ?>
|
|
|
|
|
2024-05-10 01:26:09 +02:00
|
|
|
<?php if ( comments_open() && ! $password_required ) : ?>
|
2023-01-21 01:31:34 +01:00
|
|
|
<section class="post__comments comment-section padding-left padding-right padding-bottom">
|
|
|
|
<?php comments_template(); ?>
|
|
|
|
</section>
|
|
|
|
<?php endif; ?>
|
|
|
|
|
|
|
|
<?php endwhile; ?>
|
2024-04-14 12:57:59 +02:00
|
|
|
|
2023-01-21 01:31:34 +01:00
|
|
|
</div>
|
2024-04-14 12:57:59 +02:00
|
|
|
|
2023-01-21 01:31:34 +01:00
|
|
|
</main>
|
|
|
|
|
|
|
|
<?php
|
|
|
|
// Footer arguments
|
|
|
|
$footer_args = array(
|
|
|
|
'post_type' => 'post',
|
2023-12-02 00:00:13 +01:00
|
|
|
'post_id' => $post->ID,
|
2023-01-21 01:31:34 +01:00
|
|
|
'breadcrumbs' => array(
|
|
|
|
[fcntr( 'frontpage' ), get_home_url()]
|
|
|
|
)
|
|
|
|
);
|
|
|
|
|
|
|
|
// Add current breadcrumb
|
|
|
|
$footer_args['breadcrumbs'][] = $this_breadcrumb;
|
|
|
|
|
|
|
|
// Get footer with breadcrumbs
|
|
|
|
get_footer( null, $footer_args );
|
|
|
|
?>
|