-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathloop-feed.php
More file actions
62 lines (45 loc) · 1.84 KB
/
loop-feed.php
File metadata and controls
62 lines (45 loc) · 1.84 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
<article id="post-<?php the_ID(); ?>" <?php post_class('clear'); ?>>
<?php if (has_post_thumbnail() || get_post_type() == "attachment" ) : ?>
<div class="width-25">
<?php if ( has_post_thumbnail() ) : ?>
<div class="entry-image"><?php the_post_thumbnail(); ?></div>
<?php elseif ( get_post_type() == "attachment" ) : ?>
<div class="entry-image"><?php the_content(); ?></div>
<?php endif; ?>
</div>
<?php endif; ?>
<div class="width-50">
<header class="entry-header">
<?php if ( get_post_type() == "post" ) : ?>
<h6 class="entry-date"><?php the_date('F Y'); ?></h6>
<?php endif; ?>
<h2 class="entry-title">
<?php if ( get_post_type() == "awards" ) :
$award_years = get_the_terms($post->ID,'award-years');
foreach ($award_years as $award_year) { $year = $award_year->slug; } ?>
<a href="<?php echo ( site_url('/award-years/') . $year ); ?>" rel="bookmark"><?php the_title(); ?></a>
<?php elseif ( get_post_type() == "attachment" ) : ?>
<a href="<?php echo get_permalink($post->post_parent); ?>" rel="bookmark"><?php the_title(); ?></a>
<?php else : ?>
<a href="<?php the_permalink(); ?>" rel="bookmark"><?php the_title(); ?></a>
<?php endif; ?>
</h2>
<!--
<?php if ( get_post_type() == "post" ) : ?>
<h6 class="entry-author">by <?php
if (get_field('feature_author')) { echo( get_field('feature_author') ); }
else { the_author(); }
?></h6>
<?php endif; ?>
-->
</header><!-- .entry-header -->
<div class="entry-content">
<?php if (get_post_type() == "attachment") :
else :
if ( get_the_excerpt() ) : the_excerpt();
else : the_content( __( 'Continue reading <span class="meta-nav">→</span>', 'nbr' ) );
endif;
endif; ?>
</div><!-- .entry-content -->
</div>
</article><!-- #post-## -->