author | ymh <ymh.work@gmail.com> |
Mon, 14 Oct 2019 17:39:30 +0200 | |
changeset 7 | cf61fcea0001 |
parent 5 | 5e2f62d02dcd |
permissions | -rw-r--r-- |
5 | 1 |
<?php |
2 |
/** |
|
3 |
* The default template for displaying content |
|
4 |
* |
|
5 |
* Used for both single and index/archive/search. |
|
6 |
* |
|
7 |
* @package WordPress |
|
8 |
* @subpackage Twenty_Fourteen |
|
9 |
* @since Twenty Fourteen 1.0 |
|
10 |
*/ |
|
11 |
?> |
|
12 |
||
13 |
<article id="post-<?php the_ID(); ?>" <?php post_class(); ?>> |
|
14 |
<?php twentyfourteen_post_thumbnail(); ?> |
|
15 |
||
16 |
<header class="entry-header"> |
|
17 |
<?php if ( in_array( 'category', get_object_taxonomies( get_post_type() ) ) && twentyfourteen_categorized_blog() ) : ?> |
|
18 |
<div class="entry-meta"> |
|
19 |
<span class="cat-links"><?php echo get_the_category_list( _x( ', ', 'Used between list items, there is a space after the comma.', 'twentyfourteen' ) ); ?></span> |
|
20 |
</div> |
|
21 |
<?php |
|
22 |
endif; |
|
23 |
||
7
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
24 |
if ( is_single() ) : |
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
25 |
the_title( '<h1 class="entry-title">', '</h1>' ); |
5 | 26 |
else : |
27 |
the_title( '<h1 class="entry-title"><a href="' . esc_url( get_permalink() ) . '" rel="bookmark">', '</a></h1>' ); |
|
28 |
endif; |
|
29 |
?> |
|
30 |
||
31 |
<div class="entry-meta"> |
|
32 |
<?php |
|
7
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
33 |
if ( 'post' == get_post_type() ) { |
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
34 |
twentyfourteen_posted_on(); |
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
35 |
} |
5 | 36 |
|
7
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
37 |
if ( ! post_password_required() && ( comments_open() || get_comments_number() ) ) : |
5 | 38 |
?> |
39 |
<span class="comments-link"><?php comments_popup_link( __( 'Leave a comment', 'twentyfourteen' ), __( '1 Comment', 'twentyfourteen' ), __( '% Comments', 'twentyfourteen' ) ); ?></span> |
|
40 |
<?php |
|
41 |
endif; |
|
42 |
||
43 |
edit_post_link( __( 'Edit', 'twentyfourteen' ), '<span class="edit-link">', '</span>' ); |
|
44 |
?> |
|
45 |
</div><!-- .entry-meta --> |
|
46 |
</header><!-- .entry-header --> |
|
47 |
||
48 |
<?php if ( is_search() ) : ?> |
|
49 |
<div class="entry-summary"> |
|
50 |
<?php the_excerpt(); ?> |
|
51 |
</div><!-- .entry-summary --> |
|
52 |
<?php else : ?> |
|
53 |
<div class="entry-content"> |
|
54 |
<?php |
|
55 |
/* translators: %s: Name of current post */ |
|
7
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
56 |
the_content( |
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
57 |
sprintf( |
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
58 |
__( 'Continue reading %s <span class="meta-nav">→</span>', 'twentyfourteen' ), |
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
59 |
the_title( '<span class="screen-reader-text">', '</span>', false ) |
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
60 |
) |
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
61 |
); |
5 | 62 |
|
7
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
63 |
wp_link_pages( |
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
64 |
array( |
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
65 |
'before' => '<div class="page-links"><span class="page-links-title">' . __( 'Pages:', 'twentyfourteen' ) . '</span>', |
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
66 |
'after' => '</div>', |
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
67 |
'link_before' => '<span>', |
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
68 |
'link_after' => '</span>', |
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
69 |
) |
cf61fcea0001
resynchronize code repo with production
ymh <ymh.work@gmail.com>
parents:
5
diff
changeset
|
70 |
); |
5 | 71 |
?> |
72 |
</div><!-- .entry-content --> |
|
73 |
<?php endif; ?> |
|
74 |
||
75 |
<?php the_tags( '<footer class="entry-meta"><span class="tag-links">', '', '</span></footer>' ); ?> |
|
76 |
</article><!-- #post-## --> |