PageRenderTime 33ms CodeModel.GetById 10ms RepoModel.GetById 1ms app.codeStats 0ms

/Wordpress/warp/systems/wordpress/layouts/archive.php

https://github.com/dominikkucharski/Warp-Framework
PHP | 42 lines | 36 code | 6 blank | 0 comment | 5 complexity | f4d8708cf4ee2ab8a92924830228123c MD5 | raw file
  1. <div id="system">
  2. <?php if (have_posts()) : ?>
  3. <?php if (is_category()) : ?>
  4. <?php /* <h1 class="page-title">Archive for the &#8216;<?php single_cat_title(); ?>&#8217; Category</h1> */ ?>
  5. <?php elseif (is_tag()) : ?>
  6. <h1 class="page-title"><?php printf(__('Posts Tagged %s', 'warp'), '&#8216;'.single_tag_title('', false).'&#8217;'); ?></h1>
  7. <?php elseif (is_day()) : ?>
  8. <h1 class="page-title"><?php printf(__('Archive for %s', 'warp'), get_the_date()); ?></h1>
  9. <?php elseif (is_month()) : ?>
  10. <h1 class="page-title"><?php printf(__('Archive for %s', 'warp'), get_the_date('F, Y')); ?></h1>
  11. <?php elseif (is_year()) : ?>
  12. <h1 class="page-title"><?php printf(__('Archive for %s', 'warp'), get_the_date('Y')); ?></h1>
  13. <?php elseif (is_author()) : ?>
  14. <h1 class="page-title"><?php _e('Author Archive', 'warp'); ?></h1>
  15. <?php elseif (isset($_GET['paged']) && !empty($_GET['paged'])) : ?>
  16. <h1 class="page-title"><?php _e('Blog Archives', 'warp'); ?></h1>
  17. <?php endif; ?>
  18. <?php echo $this->render('_posts'); ?>
  19. <?php echo $this->render("_pagination", array("type"=>"posts")); ?>
  20. <?php else : ?>
  21. <?php if (is_category()) : ?>
  22. <h1 class="page-title"><?php printf(__("Sorry, but there aren't any posts in the %s category yet.", "warp"), single_cat_title('', false)); ?></h1>
  23. <?php elseif (is_date()) : ?>
  24. <h1 class="page-title"><?php _e("Sorry, but there aren't any posts with this date.", "warp"); ?></h1>
  25. <?php elseif (is_author()) : ?>
  26. <?php $userdata = get_userdatabylogin(get_query_var('author_name')); ?>
  27. <h1 class="page-title"><?php printf(__("Sorry, but there aren't any posts by %s yet.", "warp"), $userdata->display_name); ?></h1>
  28. <?php else : ?>
  29. <h1 class="page-title"><?php _e("No posts found.", "warp"); ?></h1>
  30. <?php endif; ?>
  31. <?php get_search_form(); ?>
  32. <?php endif; ?>
  33. </div>