-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathheader.php
117 lines (98 loc) · 4.17 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
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
<?php
/**
* The header for our theme.
*
* This is the template that displays all of the <head> section and everything up until <div id="content">
*
* @link https://developer.wordpress.org/themes/basics/template-files/#template-partials
*
* @package Education_Zone
*/
?><!DOCTYPE html>
<html <?php language_attributes(); ?>>
<head>
<meta charset="<?php bloginfo( 'charset' ); ?>">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="profile" href="http://gmpg.org/xfn/11">
<link rel="pingback" href="<?php bloginfo( 'pingback_url' ); ?>">
<?php wp_head(); ?>
</head>
<body <?php body_class(); ?>>
<div id="page" class="site">
<header id="masthead" class="site-header" role="banner">
<?php
$phone = get_theme_mod( 'education_zone_phone' );
$email = get_theme_mod( 'education_zone_email' );
$menu_label = get_theme_mod('education_zone_top_menu_label', __('Quick Links','education-zone'));
?>
<?php if( $phone || $email || has_nav_menu( 'secondary' ) ) { ?>
<div class="header-top">
<div class="container">
<?php if( $email || $phone ){ ?>
<div class="top-links">
<?php if( $email ){ ?>
<span><i class="fa fa-envelope-o"></i><a href="mailto:<?php echo esc_attr( $email ); ?>"><?php echo esc_html( $email ); ?></a></span>
<?php } if( $phone ){ ?>
<span><i class="fa fa-phone"></i><a href="tel:<?php echo preg_replace('/\D/', '', $phone); ?>"><?php echo esc_html( $phone ); ?></a></span>
<?php } ?>
</div>
<?php } ?>
<?php
if( has_nav_menu( 'secondary' ) ){ ?>
<div id="mobile-header-2">
<a id="responsive-btn" href="#sidr-secondary"><i class="fa fa-bars"></i></a>
</div>
<nav id="secondary-navigation" class="secondary-nav" role="navigation">
<a href="javascript:void(0);"><?php echo esc_html( $menu_label ); ?></a>
<?php wp_nav_menu( array( 'theme_location' => 'secondary', 'menu_id' => 'secondary-menu', 'fallback_cb' => false ) ); ?>
</nav><!-- #site-navigation -->
<?php } ?>
</div>
</div>
<?php } ?>
<div class="header-m">
<div class="container">
<div class="site-branding">
<?php
if( function_exists( 'has_custom_logo' ) && has_custom_logo() ){
the_custom_logo();
}
?>
<?php
$description = get_bloginfo( 'description', 'display' );
if ( $description || is_customize_preview() ) : ?>
<p class="site-description"><?php echo $description; /* WPCS: xss ok. */ ?></p>
<?php
endif;
?>
<h1 class="site-title"><a href="<?php echo esc_url( home_url( '/' ) ); ?>" rel="home"><?php bloginfo( 'name' ); ?></a></h1>
</div><!-- .site-branding -->
<?php /*
<div class="form-section">
<div class="example">
<?php get_search_form(); ?>
</div>
</div>
*/ ?>
</div>
</div>
<div class="header-bottom">
<div class="container">
<div id="mobile-header">
<a id="responsive-menu-button" href="#sidr-main"><i class="fa fa-bars"></i></a>
</div>
<nav id="site-navigation" class="main-navigation" role="navigation">
<?php wp_nav_menu( array( 'theme_location' => 'primary', 'menu_id' => 'primary-menu' ) ); ?>
</nav><!-- #site-navigation -->
</div>
</div>
</header><!-- #masthead -->
<?php do_action( 'education_zone_page_header' );?>
<?php
if(!is_page_template('template-home.php')){
$class = is_404() ? 'not-found' : 'row' ;
?>
<div id="content" class="site-content">
<div class="container">
<div class="<?php echo esc_attr( $class ); ?>">
<?php }