forked from redelivre/coletivo
-
Notifications
You must be signed in to change notification settings - Fork 0
/
template-frontpage.php
54 lines (42 loc) · 1.35 KB
/
template-frontpage.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
<?php
/**
* Template Name: Frontpage
*
* @link https://developer.wordpress.org/themes/template-files-section/page-template-files/
*
* @package Coletivo
*/
get_header();
?>
<div id="content" class="site-content">
<main id="main" class="site-main" role="main">
<?php
do_action( 'coletivo_frontpage_before_section_parts' );
if ( ! has_action( 'coletivo_frontpage_section_parts' ) ) {
$section_order = get_theme_mod( 'coletivo_sections_order', 'hero,features,yourslider,featuredpage,services,portfolio,videolightbox,gallery,team,news,contact,social' );
$section_order = explode( ',', $section_order );
$sections = apply_filters( 'coletivo_frontpage_sections_order', $section_order );
foreach ( $sections as $section ) {
/**
* Hook before section
*/
do_action( 'coletivo_before_section_' . $section );
do_action( 'coletivo_before_section_part', $section );
/**
* Load section template part
*/
get_template_part( 'section-parts/section', $section );
/**
* Hook after section
*/
do_action( 'coletivo_after_section_part', $section );
do_action( 'coletivo_after_section_' . $section );
}
} else {
do_action( 'coletivo_frontpage_section_parts' );
}
do_action( 'coletivo_frontpage_after_section_parts' );
?>
</main><!-- #main -->
</div><!-- #content -->
<?php get_footer(); ?>