-
Notifications
You must be signed in to change notification settings - Fork 0
/
header.php
49 lines (35 loc) · 1.18 KB
/
header.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
<!DOCTYPE html>
<html <?php language_attributes(); ?> <?php wpboiler_the_html_classes(); ?>>
<head>
<meta charset="<?php bloginfo( 'charset' ); ?>" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<!-- <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@splidejs/splide@4.1.4/dist/css/splide.min.css"> -->
<?php wp_head(); ?>
</head>
<?php
$modifiers = array();
$showAlert = get_field('show_alert_message', 'option');
$alertMessage = get_field('alert_message', 'option');
if($showAlert && isset($alertMessage)) {
$modifiers[] = 'has__alert';
}
?>
<body <?php body_class(implode(' ', $modifiers)); ?>>
<?php
if( function_exists( 'wp_body_open' ) ) {
wp_body_open();
} else {
do_action( 'wp_body_open' );
}
?>
<div id="page" class="site">
<?php
if($showAlert && isset($alertMessage)) :
get_template_part('template-parts/alert/alert', '', array(
'show-alert' => $showAlert,
'alert-message' => $alertMessage
));
endif;
?>
<?php get_template_part( 'template-parts/header/site-header' ); ?>
<main id="main" class="site-main container__main">