forked from wdgdc/wordpress-theme
-
Notifications
You must be signed in to change notification settings - Fork 0
/
archive.php
70 lines (57 loc) · 2.23 KB
/
archive.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
<?php get_header(); ?>
<div id="content">
<?php if (is_category()) : ?>
<h1 class="archive-title archive-category-title intro-title">
<span><?php _e('Posts Categorized:', 'bonestheme'); ?></span> <?php single_cat_title(); ?>
</h1>
<?php elseif (is_tag()) : ?>
<h1 class="archive-title archive-tag-title intro-title">
<span><?php _e('Posts Tagged:', 'bonestheme'); ?></span> <?php single_tag_title(); ?>
</h1>
<?php elseif (is_author()) : ?>
<?php $author_id = $post->post_author; ?>
<h1 class="archive-title archive-author-title intro-title">
<span><?php _e('Posts By:', 'bonestheme'); ?></span> <?php the_author_meta('display_name', $author_id); ?>
</h1>
<?php elseif (is_day()) : ?>
<h1 class="archive-title archive-day-title intro-title">
<span><?php _e('Daily Archives:', 'bonestheme'); ?></span>
<?php the_time('F'); ?> <?php the_time('j'); ?>, <?php the_time('Y'); ?>
</h1>
<?php elseif (is_month()) : ?>
<h1 class="archive-title archive-month-title intro-title">
<span><?php _e('Monthly Archives:', 'bonestheme'); ?></span> <?php the_time('F Y'); ?>
</h1>
<?php elseif (is_year()) : ?>
<h1 class="archive-title archive-year-title intro-title">
<span><?php _e('Yearly Archives:', 'bonestheme'); ?></span> <?php the_time('Y'); ?>
</h1>
<?php endif; ?>
<?php while (have_posts()) : the_post(); ?>
<article id="<?php echo get_post_type(); ?>-<?php the_ID(); ?>" <?php post_class(); ?> role="article">
<div class="entry-header">
<h2 class="entry-title">
<?php the_title(); ?>
</h2>
<p class="entry-byline vcard">
<?php
$categories = (is_single()) ? ' <span class="amp">&</span> filed under %4$s' : '';
printf(
__( 'Posted <time class="updated" datetime="%1$s" pubdate>%2$s</time> by <span class="author">%3$s</span>' . $categories . '.', 'bonestheme' ),
get_the_time('Y-m-j'),
get_the_time(get_option('date_format')),
bones_get_the_author_posts_link(),
get_the_category_list(', ')
);
?>
</p>
</div>
<div class="entry-content clearfix" itemprop="articleBody">
<?php the_excerpt(); ?>
</div>
</article>
<?php endwhile; ?>
<?php bones_page_navi(); ?>
</div>
<?php get_sidebar(); ?>
<?php get_footer(); ?>