-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathsingle.php
More file actions
55 lines (39 loc) · 1.9 KB
/
single.php
File metadata and controls
55 lines (39 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
<?php
global $oes_post, $oes_container_class;
$indexClass = (!empty($oes_post->part_of_index_pages) ? ' oes-index-page' : '');
/* display header ----------------------------------------------------------------------------------------------------*/
get_header(null, ['head-text' => $oes_post ? $oes_post->get_tab_title() : get_the_title()]);
/* display main content ----------------------------------------------------------------------------------------------*/
?>
<main class="oes-smooth-loading"><?php
get_template_part('template-parts/single', 'title');
?>
<div class="oes-background-white-slim">
<div class="oes-single-post <?php echo ($oes_container_class ?? '') . $indexClass; ?>"><?php
/* display with sidebar */
if (method_exists($oes_post, 'display_sidebar') ||
is_active_sidebar('oes-single-sidebar')) :?>
<div class="row gx-5">
<div class="oes-main-content col-12 col-lg-8 oes-mt-3"><?php
the_content();
?>
</div>
<div class="oes-sidebar col-12 col-lg-4 oes-mt-3 no-print"><?php
if (method_exists($oes_post, 'display_sidebar')) :
$oes_post->display_sidebar();
else :
oes_display_sidebar('oes-single-sidebar');
endif;
?>
</div>
</div><?php
/* display without sidebar */
else:
the_content();
endif; ?>
</div>
</div>
</main>
<?php
/* display footer ----------------------------------------------------------------------------------------------------*/
get_footer();