-
Notifications
You must be signed in to change notification settings - Fork 0
/
single.php
executable file
·56 lines (34 loc) · 1.47 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
<?php get_header(); ?>
<div class="content">
<section class="post ten columns offset-by-one">
<?php if ( have_posts() ) : while ( have_posts() ) : the_post(); ?>
<article class="post">
<h1><a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>"><?php the_title(); ?></a></h1>
<p class="date">Posted <?php the_time('F j, Y'); ?> at <?php the_time('g:i a'); ?>
<?php if(get_the_tags()): ?>
in <?php the_tags('', ', '); ?>
<?php endif; ?>
</p>
<?php the_content(); ?>
</article>
<nav>
<?php
$previous_post = get_adjacent_post(false, '', true);
$next_post = get_adjacent_post(false, '', false);
if ($previous_post): ?>
<?php previous_post_link('<p class="prev"><span class="label">Previously</span><br>%link</p>', '%title', false, '92'); ?>
<?php endif; ?>
<?php if ($next_post): // if there are newer articles ?>
<?php next_post_link('<p class="next"><span class="label">Next</span><br>%link</p>', '%title', false, '92'); ?>
<?php endif; ?>
</nav>
</aside>
<?php endwhile; else: ?>
<p><?php _e('Sorry, no posts matched your criteria.'); ?></p>
<?php endif; ?>
</section>
<section class="comments ten columns offset-by-one">
<?php comments_template(); ?>
</section>
</div>
<?php get_footer(); ?>