|
1 <?php get_header(); ?> |
|
2 <?php |
|
3 if (function_exists('wp_list_comments')) { |
|
4 add_filter('get_comments_number', 'comment_count', 0); |
|
5 } |
|
6 ?> |
|
7 |
|
8 <div class="post"> |
|
9 <?php if (have_posts()) : ?> |
|
10 <div class="title bottom_space"> |
|
11 <h2> |
|
12 <?php |
|
13 $post = $posts[0]; // Hack. Set $post so that the_date() works. |
|
14 |
|
15 if (is_search()) { |
|
16 _e('Search Results', 'elegantbox'); |
|
17 } else { |
|
18 // If this is a category archive |
|
19 if (is_category()) { |
|
20 printf( __('Archive for the ‘%1$s’ Category', 'elegantbox'), single_cat_title('', false) ); |
|
21 // If this is a tag archive |
|
22 } elseif(is_tag()) { |
|
23 printf( __('Posts Tagged ‘%1$s’', 'elegantbox'), single_tag_title('', false) ); |
|
24 // If this is a daily archive |
|
25 } elseif (is_day()) { |
|
26 printf( __('Archive for %1$s', 'elegantbox'), get_the_time(__('F jS, Y', 'elegantbox')) ); |
|
27 // If this is a monthly archive |
|
28 } elseif (is_month()) { |
|
29 printf( __('Archive for %1$s', 'elegantbox'), get_the_time(__('F, Y', 'elegantbox')) ); |
|
30 // If this is a yearly archive |
|
31 } elseif (is_year()) { |
|
32 printf( __('Archive for %1$s', 'elegantbox'), get_the_time(__('Y', 'elegantbox')) ); |
|
33 // If this is an author archive |
|
34 } elseif (is_author()) { |
|
35 _e('Author Archive', 'elegantbox'); |
|
36 // If this is a paged archive |
|
37 } elseif (isset($_GET['paged']) && !empty($_GET['paged'])) { |
|
38 _e('Blog Archives', 'elegantbox'); |
|
39 } |
|
40 } |
|
41 ?> |
|
42 </h2> |
|
43 <div class="fixed"></div> |
|
44 </div><!-- title --> |
|
45 <?php endif; ?> |
|
46 |
|
47 <div class="content"> |
|
48 |
|
49 <?php if (have_posts()) : while (have_posts()) : the_post(); ?> |
|
50 <div class="boxcaption"><h3><a href="<?php the_permalink() ?>" rel="bookmark"><?php the_title(); ?></a></h3></div> |
|
51 <div class="box"> |
|
52 <div class="excerpt"> |
|
53 <?php the_excerpt(); ?> |
|
54 </div> |
|
55 <small><?php printf( __('%1$s at %2$s', 'elegantbox'), get_the_time(__('l, F jS, Y', 'elegantbox')), get_the_time(__('H:i', 'elegantbox')) ); ?> | <?php comments_popup_link(__('0 comments', 'elegantbox'), __('1 comment', 'elegantbox'), __('% comments', 'elegantbox')); ?><?php edit_post_link(__('Edit', 'elegantbox'), ' | ', ''); ?></small> |
|
56 <div><small><?php _e('Categories: ', 'elegantbox'); the_category(', ') ?></small></div> |
|
57 <div><small><?php _e('Tags: ', 'elegantbox'); the_tags('', ', ', ''); ?></small></div> |
|
58 </div> |
|
59 |
|
60 <?php endwhile; else: ?> |
|
61 <div class="messagebox"> |
|
62 <div class="content small"> |
|
63 <?php _e('Sorry, no posts matched your criteria.', 'elegantbox'); ?> |
|
64 </div> |
|
65 </div> |
|
66 |
|
67 <?php endif; ?> |
|
68 </div><!-- content --> |
|
69 </div> <!-- post --> |
|
70 |
|
71 <div class="fixed"></div> |
|
72 </div> |
|
73 |
|
74 <?php get_sidebar(); ?> |
|
75 |
|
76 <div class="fixed"></div> |
|
77 |
|
78 <div id="bottom"> |
|
79 <div class="postnav"> |
|
80 |
|
81 <?php if(function_exists('wp_pagenavi')) : ?> |
|
82 <?php wp_pagenavi() ?> |
|
83 <?php else : ?> |
|
84 <span class="alignleft"><?php previous_posts_link(__('« Newer Entries', 'elegantbox')); ?></span> |
|
85 <span class="alignright"><?php next_posts_link(__('Older Entries »', 'elegantbox')); ?></span> |
|
86 <?php endif; ?> |
|
87 |
|
88 <div class="fixed"></div> |
|
89 </div> |
|
90 |
|
91 <?php get_footer(); ?> |