-
Notifications
You must be signed in to change notification settings - Fork 0
/
page-home.php
68 lines (65 loc) · 2.58 KB
/
page-home.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
<?php
/**
* The template for displaying the home page.
*
* This is the template that displays all pages by default.
* Please note that this is the WordPress construct of pages
* and that other 'pages' on your WordPress site may use a
* different template.
*
* @link https://codex.wordpress.org/Template_Hierarchy
*
* @package Union
*/
get_header(); ?>
<?php
$feat_image = wp_get_attachment_url( get_post_thumbnail_id($post->ID) );
$carousel_image = get_attached_media( 'video' );
$quotes = get_post_meta($post->ID, 'quote');
$videos = [
'Click to see Amy Li\'s "Letter to myself" video',
'Click to see Phylis Kim Myung\'s "Letter to myself" video',
'Click to see Pata Suyemoto\'s "Letter to myself" video'
];
?>
<div id="primary" class="content-area">
<main id="main" class="site-main" role="main">
<div class="container home_container">
<div class="row">
<div class="divider"></div>
<div class="col-xs-12 col-md-6 col-md-offset-3 home_logo-container">
<img src="<?php echo $feat_image; ?>" class="logo-image" alt="TEAM Logo">
</div>
<div class="divider"></div>
</div>
</div>
<div class="container">
<?php
if (have_posts()) :
while (have_posts()) :
the_post();
the_content();
endwhile;
endif;
?>
<div class="row">
<?php
foreach (get_post_meta($post->ID, 'motto') as $motto) {
list($title, $subtitle, $url, $dest_url) = explode('|', $motto);
?>
<div class="col-xs-12 col-sm-4 call_to_action" style="background-image: url(<?php echo $url; ?>);">
<a href="<?php echo $dest_url; ?>">
<div class="call_to_action-overlay"></div>
<div class="call_to_action-title"><?php echo $title; ?></div>
<div class="call_to_action-subtitle"><?php echo $subtitle; ?></div>
</a>
</div>
<?php
}
?>
</div>
</div>
</main><!-- #main -->
</div><!-- #primary -->
<?php
get_footer();