PageRenderTime 45ms CodeModel.GetById 25ms RepoModel.GetById 0ms app.codeStats 0ms

/wordpress3.4.2/wp-content/themes/twentyeleven/content-single.php

https://bitbucket.org/ch3tag/mothers
PHP | 71 lines | 55 code | 7 blank | 9 comment | 9 complexity | a561cc14311314e6975758a9ffafdd30 MD5 | raw file
  1. <?php
  2. /**
  3. * The template for displaying content in the single.php template
  4. *
  5. * @package WordPress
  6. * @subpackage Twenty_Eleven
  7. * @since Twenty Eleven 1.0
  8. */
  9. ?>
  10. <article id="post-<?php the_ID(); ?>" <?php post_class(); ?>>
  11. <header class="entry-header">
  12. <h1 class="entry-title"><?php the_title(); ?></h1>
  13. <?php if ( 'post' == get_post_type() ) : ?>
  14. <div class="entry-meta">
  15. <?php twentyeleven_posted_on(); ?>
  16. </div><!-- .entry-meta -->
  17. <?php endif; ?>
  18. </header><!-- .entry-header -->
  19. <div class="entry-content">
  20. <?php the_content(); ?>
  21. <?php wp_link_pages( array( 'before' => '<div class="page-link"><span>' . __( 'Pages:', 'twentyeleven' ) . '</span>', 'after' => '</div>' ) ); ?>
  22. </div><!-- .entry-content -->
  23. <footer class="entry-meta">
  24. <?php
  25. /* translators: used between list items, there is a space after the comma */
  26. $categories_list = get_the_category_list( __( ', ', 'twentyeleven' ) );
  27. /* translators: used between list items, there is a space after the comma */
  28. $tag_list = get_the_tag_list( '', __( ', ', 'twentyeleven' ) );
  29. if ( '' != $tag_list ) {
  30. $utility_text = __( 'This entry was posted in %1$s and tagged %2$s by <a href="%6$s">%5$s</a>. Bookmark the <a href="%3$s" title="Permalink to %4$s" rel="bookmark">permalink</a>.', 'twentyeleven' );
  31. } elseif ( '' != $categories_list ) {
  32. $utility_text = __( 'This entry was posted in %1$s by <a href="%6$s">%5$s</a>. Bookmark the <a href="%3$s" title="Permalink to %4$s" rel="bookmark">permalink</a>.', 'twentyeleven' );
  33. } else {
  34. $utility_text = __( 'This entry was posted by <a href="%6$s">%5$s</a>. Bookmark the <a href="%3$s" title="Permalink to %4$s" rel="bookmark">permalink</a>.', 'twentyeleven' );
  35. }
  36. printf(
  37. $utility_text,
  38. $categories_list,
  39. $tag_list,
  40. esc_url( get_permalink() ),
  41. the_title_attribute( 'echo=0' ),
  42. get_the_author(),
  43. esc_url( get_author_posts_url( get_the_author_meta( 'ID' ) ) )
  44. );
  45. ?>
  46. <?php edit_post_link( __( 'Edit', 'twentyeleven' ), '<span class="edit-link">', '</span>' ); ?>
  47. <?php if ( get_the_author_meta( 'description' ) && ( ! function_exists( 'is_multi_author' ) || is_multi_author() ) ) : // If a user has filled out their description and this is a multi-author blog, show a bio on their entries ?>
  48. <div id="author-info">
  49. <div id="author-avatar">
  50. <?php echo get_avatar( get_the_author_meta( 'user_email' ), apply_filters( 'twentyeleven_author_bio_avatar_size', 68 ) ); ?>
  51. </div><!-- #author-avatar -->
  52. <div id="author-description">
  53. <h2><?php printf( __( 'About %s', 'twentyeleven' ), get_the_author() ); ?></h2>
  54. <?php the_author_meta( 'description' ); ?>
  55. <div id="author-link">
  56. <a href="<?php echo esc_url( get_author_posts_url( get_the_author_meta( 'ID' ) ) ); ?>" rel="author">
  57. <?php printf( __( 'View all posts by %s <span class="meta-nav">&rarr;</span>', 'twentyeleven' ), get_the_author() ); ?>
  58. </a>
  59. </div><!-- #author-link -->
  60. </div><!-- #author-description -->
  61. </div><!-- #author-info -->
  62. <?php endif; ?>
  63. </footer><!-- .entry-meta -->
  64. </article><!-- #post-<?php the_ID(); ?> -->