PageRenderTime 128ms CodeModel.GetById 12ms RepoModel.GetById 0ms app.codeStats 0ms

/blog/wp-content/themes/fadtastic/index.php

https://bitbucket.org/sergiohzlz/reportaprod
PHP | 73 lines | 64 code | 9 blank | 0 comment | 12 complexity | 11b7acb3faf4a599331a011b963968a3 MD5 | raw file
Possible License(s): GPL-2.0, GPL-3.0, AGPL-1.0, LGPL-2.1
  1. <?php get_header(); ?>
  2. <div id="content_wrapper">
  3. <div id="content">
  4. <?php if ( have_posts() ) : ?>
  5. <?php while ( have_posts() ) : the_post(); $loopcounter++; ?>
  6. <?php if ( $loopcounter == 1 || is_sticky() ) { $saved_ids[] = get_the_ID(); ?>
  7. <h1 id="post-<?php the_ID(); ?>" ><a href="<?php the_permalink(); ?>" rel="bookmark" title="<?php echo esc_attr( sprintf( __( 'Permanent link to %s' ), the_title_attribute( 'echo=0' ) ) ); ?>"><?php the_title(); ?></a></h1>
  8. <p class="author fresh" ><?php _e( 'Posted on' ); ?> <em><?php the_time( get_option( 'date_format' ) ); ?></em>. <?php _e( 'Filed under:', 'fadtastic' ); ?> <?php the_category( ', ' ); ?> | <?php the_tags( __( 'Tags: ' ), ', ', ' | ' ); ?> <?php edit_post_link( __( 'Edit This' ) ); ?></p>
  9. <?php the_content(); ?>
  10. <br class="clear" />
  11. <big>
  12. <strong><a href="<?php the_permalink(); ?>" rel="bookmark" title="<?php echo esc_attr( sprintf( __( 'Permanent link to %s' ), the_title_attribute( 'echo=0' ) ) ); ?>"><?php _e( 'Read Full Post', 'fadtastic' ); ?></a></strong> |
  13. <strong>
  14. <?php if ('open' == $post->comment_status) : ?>
  15. <a href="<?php the_permalink(); ?>#respond" title="Make a comment"><?php _e( 'Make a Comment' ); ?></a>
  16. <?php else : ?>
  17. <?php _e( 'Comments are Closed' ); ?>
  18. <?php endif;?>
  19. </strong>
  20. <small>
  21. <?php if ('open' == $post->comment_status) : ?>
  22. ( <?php comments_popup_link( __( 'None so far' ), __( '<strong>1</strong> so far' ), ( '<strong>%</strong> so far' ) ); ?> )
  23. <?php endif; ?>
  24. </small>
  25. </big>
  26. <?php } ?>
  27. <?php endwhile; ?>
  28. <?php else : ?>
  29. <h2><?php _e( 'Not Found', 'fadtastic' ); ?></h2>
  30. <p><?php _e( "Sorry, but you are looking for something that isn't here.", 'fadtastic' ); ?></p>
  31. <?php get_search_form(); ?>
  32. <?php endif; ?>
  33. <!-- Minor posts start here -->
  34. <h2 class="recently"><?php _e( 'Recently on', 'fadtastic' ); ?> <?php bloginfo('name'); ?>...</h2>
  35. <?php
  36. query_posts( array(
  37. 'showposts' => 10,
  38. 'post__not_in' => $saved_ids,
  39. ));
  40. ?>
  41. <?php if ( have_posts() ) : ?>
  42. <?php while ( have_posts() ) : the_post(); ?>
  43. <?php if( !is_sticky() ) :?>
  44. <div class="recent_post">
  45. <h2 id="post-<?php the_ID(); ?>" ><a href="<?php the_permalink(); ?>" rel="bookmark" title="<?php echo esc_attr( sprintf( __( 'Permanent link to %s' ), the_title_attribute( 'echo=0' ) ) ); ?>"><?php the_title(); ?></a></h2>
  46. <p class="author" ><?php _e( 'Posted on' ); ?> <em><?php the_time( get_option( 'date_format' ) ); ?></em>. <?php _e( 'Filed under:', 'fadtastic' ); ?> <?php the_category( ', ' ); ?> | <?php the_tags( __( 'Tags: ' ), ', ', ' | ' ); ?> <?php edit_post_link( __( 'Edit This' ) ); ?></p>
  47. </div>
  48. <?php endif; endwhile; ?>
  49. <?php else : ?>
  50. <h2><?php _e( 'Not Found', 'fadtastic' ); ?></h2>
  51. <p><?php _e( "Sorry, but you are looking for something that isn't here.", 'fadtastic' ); ?></p>
  52. <?php get_search_form(); ?>
  53. <?php endif; ?>
  54. </div>
  55. </div>
  56. <?php get_sidebar(); ?>
  57. <?php get_footer(); ?>