-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathsingle-portfolio.php
52 lines (43 loc) · 1.58 KB
/
single-portfolio.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
<?php $details = getPorfolioPostDetails(get_the_ID()); ?>
<?php get_header() ?>
<div class="large-12 columns portfolio-post-header"
style="background-image:url(<?= $details['featured'] ?>)"
>
<?php get_template_part('template-parts/header-alone') ?>
</div>
<?php
foreach($details['sections'] as $section) {
//crear variables
set_query_var( 'background', $section['background'] );
set_query_var( 'title', $section['title'] );
set_query_var( 'subtitle', $section['subtitle'] );
set_query_var( 'methods', $section['methods'] );
set_query_var( 'image', $section['image'] );
set_query_var( 'content', $section['content'] );
set_query_var( 'video', $section['video_url'] );
if($section['layout'] == 1){
get_template_part('template-parts/left-to-right-portfolio');
}else{
get_template_part('template-parts/right-to-left-portfolio');
}
}
?>
<div class="large-12 columns section align-center contact-page"
style="padding:50px 0;"
>
<img src="<?= get_template_directory_uri() . '/images/love-icon.jpg' ?>" alt="" />
<h4 class="align-center">Thanks for watching</h4>
<a href="<?= site_url() ?>/portfolio">
<span class="align-center small-bold">CHECK OUT RELATED WORK</span>
</a>
<ul class="navigation">
<?php if(get_adjacent_post(false, '', true)) {?>
<li><?php previous_post_link() ?> | <span class="prev-link">Previous</span></li>
<?php }?>
<?php if(get_adjacent_post(false, '', false)) {?>
<li><span class="next-link">Next</span> | <?php next_post_link() ?></li>
<?php }?>
</ul>
</div>
<?php get_template_part('template-parts/footer-page') ?>
<?php get_footer() ?>