-
Notifications
You must be signed in to change notification settings - Fork 39
/
single.php
84 lines (57 loc) · 1.77 KB
/
single.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
<?php
/**
* Single Posts Template
*
* @link http://codex.wordpress.org/Template_Hierarchy
*
* @package Scaffolding
*/
get_header();
?>
<div id="inner-content" class="container">
<div id="main" class="clearfix" role="main">
<?php
if ( have_posts() ) :
while ( have_posts() ) :
the_post();
?>
<article id="post-<?php the_ID(); ?>" <?php post_class( 'clearfix' ); ?> role="article" itemscope itemtype="http://schema.org/BlogPosting">
<header class="entry-header clearfix">
<h1 class="single-title" itemprop="headline"><?php the_title(); ?></h1>
<?php echo scaffolding_post_meta(); // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped ?>
</header>
<section class="entry-content clearfix" itemprop="articleBody">
<?php
the_content();
wp_link_pages(
array(
'before' => '<div class="page-links"><span class="page-links-title">' . __( 'Pages:', 'scaffolding' ) . '</span>',
'after' => '</div>',
'link_before' => '<span>',
'link_after' => '</span>',
)
);
?>
</section>
<?php if ( get_the_tag_list() ) : ?>
<footer class="entry-footer clearfix">
<?php the_tags( '<p class="tags"><span class="tags-title">Tags:</span> ', ', ', '</p>' ); ?>
</footer>
<?php endif; ?>
<?php
// If comments are open or we have at least one comment, load up the comment template.
if ( comments_open() || '0' !== get_comments_number() ) :
comments_template();
endif;
?>
</article>
<?php
endwhile;
else :
get_template_part( 'template-parts/error' ); // WordPress template error message.
endif;
?>
</div><?php // END #main. ?>
</div><?php // END #inner-content. ?>
<?php
get_footer();