-
Notifications
You must be signed in to change notification settings - Fork 15
/
page-speakers.php
94 lines (77 loc) · 2.63 KB
/
page-speakers.php
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
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
<?php
/*
Template Name: Speakers
*/
?>
<?php get_header(); ?>
<div class="row">
<div class="twelve columns">
<?php get_template_part('loop', 'page'); ?>
<h2>2012 Speakers</h2>
<?php
$newspeaker_args = array(
'post_type' => 'speakers',
'taxonomy' => 'tedxyycYear',
'term' => '2012',
'orderby' => 'title',
'order' => 'ASC',
);
$newspeaker_query = new WP_Query($newspeaker_args);
?>
<?php /* Start loop */ ?>
<?php $i = 0; ?>
<?php while ($newspeaker_query->have_posts()) : $newspeaker_query->the_post(); ?>
<?php if ($i%3 == 0 && $i != 0) { echo '</ul>'; } ?>
<?php if ($i%3 == 0) { echo '<ul class="row clearfix new">'; } ?>
<li class="four columns speaker">
<a href="<?php the_permalink(); ?>" class="speakerLink">
<?php the_post_thumbnail('wide_thumb', array(
'alt' => ''.get_the_title().'',
'title' => ''.get_the_title().''
)); ?>
</a>
<p><strong><?php the_title(); ?></strong><br/>
<span><?php echo get_post_meta($post->ID, '_tedxyyc_speaker_jobposition_value', true) ?><br /> <em><?php echo get_post_meta($post->ID, '_tedxyyc_speaker_employer_value', true) ?></em></span></p>
<p><?php new_excerpt(300); ?></p>
<p><a href="<?php the_permalink(); ?>" class="readMore" >Read <?php echo get_post_meta($post->ID, '_tedxyyc_speaker_firstname_value', true) ?>'s Bio</a></p>
</li>
<?php
$i++;
endwhile; // End the loop
echo '</ul>';
?>
<div class="clearfix"></div>
<h2>2011 Speakers</h2>
<?php
$oldspeaker_args = array(
'post_type' => 'speakers',
'taxonomy' => 'tedxyycYear',
'term' => '2011',
'orderby' => 'title',
'order' => 'ASC',
);
$oldspeaker_query = new WP_Query($oldspeaker_args);
?>
<?php /* Start loop */ ?>
<?php $i = 0; ?>
<?php while ($oldspeaker_query->have_posts()) : $oldspeaker_query->the_post(); ?>
<?php if ($i%3 == 0 && $i != 0) { echo '</ul>'; } ?>
<?php if ($i%3 == 0) { echo '<ul class="row clearfix old">'; } ?>
<li class="four columns speaker">
<a href="<?php the_permalink(); ?>" class="speakerLink">
<?php the_post_thumbnail('wide_thumb', array(
'alt' => ''.get_the_title().'',
'title' => ''.get_the_title().''
)); ?>
</a>
<p><strong><?php the_title(); ?></strong><br/>
<span><?php echo get_post_meta($post->ID, '_tedxyyc_speaker_jobposition_value', true) ?><br /> <em><?php echo get_post_meta($post->ID, '_tedxyyc_speaker_employer_value', true) ?></em></span></p>
</li>
<?php
$i++;
endwhile; // End the loop
echo '</ul>';
?>
</div>
</div>
<?php get_footer(); ?>