-
-
Notifications
You must be signed in to change notification settings - Fork 1
/
template-about-staff.php
64 lines (47 loc) · 1.61 KB
/
template-about-staff.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
<?php /* Template name: Staff */
// header
get_header();
// team banner
$team_banner = get_field('team_banner');
include( 'modules/banner--team.php' );
// define team member posts to display
$staff_members = get_field('staff_members');
// cycle through selected posts
foreach( $staff_members as $post ) {
// setup post data for each post
setup_postdata( $post );
$profile_picture = get_field('profile_picture');
$name = get_the_title();
$title = get_field('leadership_title');
$bio = get_field('bio');
$location = get_field('contributor_location');
$linkedin = get_field('linkedin');
$website = get_field('website');
$twitter = get_field('twitter');
$email = get_field('email');
$personal_languages = get_field('languages');
// show board member module
include( 'modules/team-member--wide.php' );
} wp_reset_postdata();
// define volunteer+intern team member posts to display acf
// cycle through selected posts
$interns_and_volunteers = get_field('interns_and_volunteers');
if ( $interns_and_volunteers ) {
// cycle through selected posts
foreach( $interns_and_volunteers as $post ) {
// setup post data for each post
setup_postdata( $post );
// variables - would be cool to add a
$profile_picture = get_field('profile_picture');
$name = get_the_title();
$title = get_field('leadership_title');
$location = get_field('contributor_location');
$linkedin = get_field('linkedin');
$website = get_field('website');
$twitter = get_field('twitter');
$email = get_field('email');
// show board member module
include( 'modules/team-member--grid.php' );
} wp_reset_postdata();
}
get_footer();