-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathheader.php
More file actions
63 lines (58 loc) · 1.93 KB
/
header.php
File metadata and controls
63 lines (58 loc) · 1.93 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
59
60
61
62
63
<?php
?><!doctype html>
<html <?php language_attributes(); ?>>
<head>
<meta charset="<?php bloginfo( 'charset' ); ?>">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="preload"
href="<?php echo get_template_directory_uri(); ?>/fonts/lato-400-regular.woff2"
as="font"
type="font/woff2"
crossorigin>
<?php if ( is_singular( 'event' ) ) : ?>
<script src="https://maps.googleapis.com/maps/api/js?key=AIzaSyBhXc-P0oJLSCbmNRnLOO-Q5XnjcpISEQs&callback=Function.prototype"></script>
<?php endif; ?>
<?php wp_head(); ?>
</head>
<body <?php body_class(); ?>>
<?php get_template_part( 'partials/preloader' ); ?>
<?php /* <button id="themeBtn"><i class="far fa-moon"></i></button> */ ?>
<?php get_template_part('partials/sticky-header') ?>
<?php get_template_part('partials/search-popup') ?>
<?php
$header_args = isset( $args ) && is_array( $args ) ? $args : array();
$header_variant = isset( $header_args['header_variant'] ) ? $header_args['header_variant'] : 'default';
$header_color = isset( $header_args['header_color'] ) ? $header_args['header_color'] : 'default';
$header_classes = array(
$header_variant === 'absolute' ? 'cwp-header-absolute' : 'cwp-header-standard',
);
if ( $header_color === 'white' ) {
$header_classes[] = 'white';
}
$header_class = implode( ' ', $header_classes );
?>
<header class="<?php echo esc_attr( $header_class ); ?>">
<div class="header-menu-area">
<div class="flex items-center justify-between">
<div class="header-logo">
<?php get_template_part( 'partials/logo' ); ?>
</div>
<?php get_template_part( 'partials/header-links' ); ?>
</div>
<button class="hamburger popup-menu" data-menu="mobileMenu">
<span></span>
<span></span>
<span></span>
</button>
</div>
</header>
<?php
get_template_part(
'partials/mobile-menu',
null,
array(
'header_color' => $header_color,
)
);
?>
<main id="main-content">