-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathsingle.php
44 lines (42 loc) · 1.06 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
<?php get_header(); ?>
<!-- Main -->
<div id="main">
<!-- Post -->
<section class="post">
<?php
if ( have_posts() ) :
while ( have_posts() ) : the_post();
?>
<header class="major">
<span class="date"><?php echo get_the_date('M d, Y') ?></span>
<h1><?php the_title(); ?></h1>
</header>
<div class="image main">
<?php
if ( has_post_thumbnail() ) {
the_post_thumbnail( '', ['alt' => get_the_title()] );
} else {
echo '<img src="'. get_theme_file_uri() .'/images/pic02.jpg" alt="'. get_the_title() .'" />';
}
?>
</div>
<?php
the_content();
the_tags( __( '<b>Tags: </b>', 'massively' ), ', ', '' );
if ( !post_password_required() ) {
$defaults = array(
'before' => '<div class="link-pages">'. __( 'Pages: ', 'massively' ),
'after' => '</div>'
);
wp_link_pages( $defaults );
}
endwhile;
endif;?>
</section>
<?php if ( comments_open() || get_comments_number() ) : ?>
<section>
<?php comments_template(); ?>
</section>
<?php endif; ?>
</div>
<?php get_footer(); ?>