-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpage-faq.php
More file actions
58 lines (43 loc) · 1.9 KB
/
page-faq.php
File metadata and controls
58 lines (43 loc) · 1.9 KB
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
<?php
/**
* General page template
*/
/* Template Name: FAQ */
get_header(); ?>
<div class="site-content">
<?php while ( have_posts() ) : the_post(); ?>
<?php get_template_part('partials/page', 'preface'); ?>
<?php endwhile; ?>
<?php if( have_rows('faq_module') ): ?>
<?php while( have_rows('faq_module') ): the_row(); ?>
<section class="module module--basic module--faq u-bg-light-gray">
<div class="module__content u-container">
<header class="module__header">
<div class="module-title">
<?php the_sub_field('faq_module_title'); ?>
</div>
</header>
<div class="module__body">
<?php if( have_rows('faq_item') ): ?>
<?php while( have_rows('faq_item') ): the_row(); ?>
<div class="dropdown">
<div class="dropdown__title js-slide-toggle" data-target=".dropdown__content" data-parent=".dropdown">
<h5><?php the_sub_field('question'); ?></h5>
<span class="dropdown__icon"></span>
</div>
<div class="dropdown__content">
<?php the_sub_field('answer'); ?>
</div>
</div>
<?php endwhile; ?>
<?php endif; ?>
</div>
</div>
</section>
<?php
endwhile;
wp_reset_postdata();
?>
<?php endif; ?>
</div>
<?php get_footer(); ?>