PageRenderTime 58ms CodeModel.GetById 24ms RepoModel.GetById 0ms app.codeStats 0ms

/content-single.php

https://github.com/lecar-red/3ring-wordpress
PHP | 55 lines | 43 code | 8 blank | 4 comment | 8 complexity | 618d8dfd3306c15fa5114c594b4cede8 MD5 | raw file
Possible License(s): AGPL-1.0
  1. <?php
  2. /**
  3. * @package WordPress
  4. * @subpackage Yoko
  5. */
  6. ?>
  7. <article id="post-<?php the_ID(); ?>" <?php post_class(); ?>>
  8. <?php if ( has_post_thumbnail()) : ?>
  9. <div class="single-entry-details">
  10. <a href="<?php the_permalink(); ?>"><?php the_post_thumbnail('thumbnail'); ?></a>
  11. </div><!-- end single-entry-details -->
  12. <?php endif; ?>
  13. <header class="single-entry-header">
  14. <h1 class="entry-title"><?php the_title(); ?></h1>
  15. <p><span class="entry-date"><?php echo get_the_date(); ?></span> <span class="entry-author"><?php _e( 'by', 'yoko' ); ?> <?php the_author() ?></span> <?php if ( comments_open() ) : ?> | <?php comments_popup_link( __( '0 comments', 'yoko' ), __( '1 Comment', 'yoko' ), __( '% Comments', 'yoko' ) ); ?><?php endif; ?></p>
  16. </header><!-- end single-entry-header -->
  17. <div class="single-entry-content">
  18. <?php if ( is_archive() || is_search() ) : // Only display excerpts for archives and search. ?>
  19. <?php the_excerpt(); ?>
  20. <?php else : ?>
  21. <?php the_content( __( 'Continue Reading &rarr;', 'yoko' ) ); ?>
  22. <div class="clear"></div>
  23. <?php wp_link_pages( array( 'before' => '<div class="page-link">' . __( 'Pages:', 'yoko' ), 'after' => '</div>' ) ); ?>
  24. <?php endif; ?>
  25. <footer class="single-entry-meta">
  26. <p><?php if ( count( get_the_category() ) ) : ?>
  27. <?php printf( __( 'Categories: %2$s', 'yoko' ), 'entry-utility-prep entry-utility-prep-cat-links', get_the_category_list( ', ' ) ); ?> |
  28. <?php endif; ?>
  29. <?php $tags_list = get_the_tag_list( '', ', ' );
  30. if ( $tags_list ): ?>
  31. <?php printf( __( 'Tags: %2$s', 'yoko' ), 'entry-utility-prep entry-utility-prep-tag-links', $tags_list ); ?> |
  32. <?php endif; ?>
  33. <a href="<?php echo get_permalink(); ?>"><?php _e( 'Permalink ', 'yoko' ); ?></a>
  34. <?php edit_post_link( __( 'Edit &rarr;', 'yoko' ), '| <span class="edit-link">', '</span>' ); ?></p>
  35. </footer><!-- end entry-meta -->
  36. <?php if ( get_the_author_meta( 'description' ) ) : ?>
  37. <div class="author-info">
  38. <?php echo get_avatar( get_the_author_meta( 'user_email' ), apply_filters( 'yoko_author_bio_avatar_size', 70 ) ); ?>
  39. <div class="author-description">
  40. <h3><?php printf( __( 'Author: %s', 'yoko' ), "<a href='" . get_author_posts_url( get_the_author_meta( 'ID' ) ) . "' title='" . esc_attr( get_the_author() ) . "' rel='me'>" . get_the_author() . "</a>" ); ?></h3>
  41. <p><?php the_author_meta( 'description' ); ?></p>
  42. </div><!-- end author-description -->
  43. </div><!-- end author-info -->
  44. <?php endif; ?>
  45. </div><!-- end single-entry-content -->
  46. </article><!-- end post-<?php the_ID(); ?> -->
  47. <div class="clear"></div>