[44] | 1 | <?php
|
---|
| 2 | /**
|
---|
| 3 | * @package WordPress
|
---|
| 4 | * @subpackage Default_Theme
|
---|
| 5 | */
|
---|
| 6 |
|
---|
| 7 | get_header();
|
---|
| 8 | ?>
|
---|
| 9 |
|
---|
| 10 | <div id="content" class="narrowcolumn" role="main">
|
---|
| 11 |
|
---|
| 12 | <?php if (have_posts()) : ?>
|
---|
| 13 |
|
---|
| 14 | <?php $post = $posts[0]; // Hack. Set $post so that the_date() works. ?>
|
---|
| 15 | <?php /* If this is a category archive */ if (is_category()) { ?>
|
---|
| 16 | <h2 class="pagetitle"><?php printf(__('Archive for the ‘%s’ Category', 'kubrick'), single_cat_title('', false)); ?></h2>
|
---|
| 17 | <?php /* If this is a tag archive */ } elseif( is_tag() ) { ?>
|
---|
| 18 | <h2 class="pagetitle"><?php printf(__('Posts Tagged ‘%s’', 'kubrick'), single_tag_title('', false) ); ?></h2>
|
---|
| 19 | <?php /* If this is a daily archive */ } elseif (is_day()) { ?>
|
---|
| 20 | <h2 class="pagetitle"><?php printf(_c('Archive for %s|Daily archive page', 'kubrick'), get_the_time(__('F jS, Y', 'kubrick'))); ?></h2>
|
---|
| 21 | <?php /* If this is a monthly archive */ } elseif (is_month()) { ?>
|
---|
| 22 | <h2 class="pagetitle"><?php printf(_c('Archive for %s|Monthly archive page', 'kubrick'), get_the_time(__('F, Y', 'kubrick'))); ?></h2>
|
---|
| 23 | <?php /* If this is a yearly archive */ } elseif (is_year()) { ?>
|
---|
| 24 | <h2 class="pagetitle"><?php printf(_c('Archive for %s|Yearly archive page', 'kubrick'), get_the_time(__('Y', 'kubrick'))); ?></h2>
|
---|
| 25 | <?php /* If this is an author archive */ } elseif (is_author()) { ?>
|
---|
| 26 | <h2 class="pagetitle"><?php _e('Author Archive', 'kubrick'); ?></h2>
|
---|
| 27 | <?php /* If this is a paged archive */ } elseif (isset($_GET['paged']) && !empty($_GET['paged'])) { ?>
|
---|
| 28 | <h2 class="pagetitle"><?php _e('Blog Archives', 'kubrick'); ?></h2>
|
---|
| 29 | <?php } ?>
|
---|
| 30 |
|
---|
| 31 |
|
---|
| 32 | <div class="navigation">
|
---|
| 33 | <div class="alignleft"><?php next_posts_link(__('« Older Entries', 'kubrick')); ?></div>
|
---|
| 34 | <div class="alignright"><?php previous_posts_link(__('Newer Entries »', 'kubrick')); ?></div>
|
---|
| 35 | </div>
|
---|
| 36 |
|
---|
| 37 | <?php while (have_posts()) : the_post(); ?>
|
---|
| 38 | <div <?php post_class(); ?>>
|
---|
| 39 | <h3 id="post-<?php the_ID(); ?>"><a href="<?php the_permalink() ?>" rel="bookmark" title="<?php printf(__('Permanent Link to %s', 'kubrick'), the_title_attribute('echo=0')); ?>"><?php the_title(); ?></a></h3>
|
---|
| 40 | <small><?php the_time(__('l, F jS, Y', 'kubrick')) ?></small>
|
---|
| 41 |
|
---|
| 42 | <div class="entry">
|
---|
| 43 | <?php the_content() ?>
|
---|
| 44 | </div>
|
---|
| 45 |
|
---|
| 46 | <p class="postmetadata"><?php the_tags(__('Tags:', 'kubrick'), ', ', '<br />'); ?> <?php printf(__('Posted in %s', 'kubrick'), get_the_category_list(', ')); ?> | <?php edit_post_link(__('Edit', 'kubrick'), '', ' | '); ?> <?php comments_popup_link(__('No Comments »', 'kubrick'), __('1 Comment »', 'kubrick'), __('% Comments »', 'kubrick'), '', __('Comments Closed', 'kubrick') ); ?></p>
|
---|
| 47 |
|
---|
| 48 | </div>
|
---|
| 49 |
|
---|
| 50 | <?php endwhile; ?>
|
---|
| 51 |
|
---|
| 52 | <div class="navigation">
|
---|
| 53 | <div class="alignleft"><?php next_posts_link(__('« Older Entries', 'kubrick')); ?></div>
|
---|
| 54 | <div class="alignright"><?php previous_posts_link(__('Newer Entries »', 'kubrick')); ?></div>
|
---|
| 55 | </div>
|
---|
| 56 | <?php else :
|
---|
| 57 |
|
---|
| 58 | if ( is_category() ) { // If this is a category archive
|
---|
| 59 | printf("<h2 class='center'>".__("Sorry, but there aren't any posts in the %s category yet.", 'kubrick').'</h2>', single_cat_title('',false));
|
---|
| 60 | } else if ( is_date() ) { // If this is a date archive
|
---|
| 61 | echo('<h2>'.__("Sorry, but there aren't any posts with this date.", 'kubrick').'</h2>');
|
---|
| 62 | } else if ( is_author() ) { // If this is a category archive
|
---|
| 63 | $userdata = get_userdatabylogin(get_query_var('author_name'));
|
---|
| 64 | printf("<h2 class='center'>".__("Sorry, but there aren't any posts by %s yet.", 'kubrick')."</h2>", $userdata->display_name);
|
---|
| 65 | } else {
|
---|
| 66 | echo("<h2 class='center'>".__('No posts found.', 'kubrick').'</h2>');
|
---|
| 67 | }
|
---|
| 68 | get_search_form();
|
---|
| 69 | endif;
|
---|
| 70 | ?>
|
---|
| 71 | </div>
|
---|
| 72 |
|
---|
| 73 | <?php get_sidebar(); ?>
|
---|
| 74 |
|
---|
| 75 | <?php get_footer(); ?>
|
---|