header-brokerlanding.php
6.99 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
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
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
<?php include 'staging-lock.php'; ?>
<!DOCTYPE html>
<!--[if lt IE 7]>
<html class="no-js lt-ie9 lt-ie8 lt-ie7" <?php language_attributes() ?>><![endif]-->
<!--[if IE 7]>
<html class="no-js lt-ie9 lt-ie8" <?php language_attributes() ?>><![endif]-->
<!--[if IE 8]>
<style>
<html class="no-js lt-ie9" <?php language_attributes() ?>><![endif]-->
<!--[if gt IE 8]><!-->
<html class="no-js" <?php language_attributes() ?>>
<!--<![endif]-->
<head>
<meta charset="<?php bloginfo('charset') ?>">
<!--[if IE]>
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<!--[if IE 9]>
<style>
.peopleOpen {
margin-right:220px !important;
}
</style>
<![endif]-->
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width" />
<meta name="facebook-domain-verification" content="yvu0p7s5ycmx5htkiw6wn8hmyb2rbo" />
<title><?php wp_title(' » ', true, 'right'); ?>The Commonwell</title>
<script>
dataLayer = [{
'userId': '<?php echo get_current_user_id(); ?>'
}];
</script>
<script>
(function(w, d, s, l, i) {
w[l] = w[l] || [];
w[l].push({
'gtm.start': new Date().getTime(),
event: 'gtm.js'
});
var f = d.getElementsByTagName(s)[0],
j = d.createElement(s),
dl = l != 'dataLayer' ? '&l=' + l : '';
j.async = true;
j.src =
'//www.googletagmanager.com/gtm.js?id=' + i + dl;
f.parentNode.insertBefore(j, f);
})(window, document, 'script', 'dataLayer', 'GTM-MWQJ2F');
</script>
<link rel="shortcut icon" type="image/x-icon" href="<?php bloginfo('url'); ?>/favicon.ico">
<link rel="apple-touch-icon" href="<?php bloginfo('url'); ?>/apple-touch-icon.png">
<?php wp_head() ?>
<script>
window.isBrokerPage = true;
</script>
</head>
<body <?php body_class() ?>>
<!-- Google Tag Manager -->
<noscript><iframe src="//www.googletagmanager.com/ns.html?id=GTM-MWQJ2F" height="0" width="0" style="display:none;visibility:hidden"></iframe></noscript>
<!-- End Google Tag Manager -->
<!--[if lt IE 7]>
<p class="browsehappy">You are using an <strong>outdated</strong> browser. Please <a href="http://browsehappy.com/">upgrade
your browser</a> to improve your experience.</p>
<![endif]-->
<?php $current_user = wp_get_current_user(); ?>
<div id="content-wrap">
<?php
if (function_exists(clean_custom_moblie_menus())) clean_custom_moblie_menus();
?>
<style>
@media screen and (max-device-width: 480px) {
body {
-webkit-text-size-adjust: 100%;
}
}
</style>
<header id="page-header-landing">
<div id="other-header">
<div class="row">
<div class="col-xs-3 col-sm-3 col-md-3 col-lg-3">
<div id="page-logo">
<a href="<?php bloginfo('url') ?>" title="<?php bloginfo('name') ?> - <?php bloginfo('description') ?>">
<img id="otherpage-logo" src="<?php bloginfo('template_directory') ?>/images/Commonwell-logo.svg" alt="Commonwell Mutual Insurance Group logo" />
</a>
</div>
</div>
<div class="col-xs-9 col-sm-9 col-md-9 col-md-9">
<div class="row">
<div id='header'>
<?php wp_nav_menu(
array(
'theme_location' => 'broker-header',
'container' => 'nav',
'container_id' => 'broker-header',
)
);
echo do_shortcode(
'[searchwp_search_form target="' . get_option('home') . '/search-results/" engine="default" var="searchvar" ]'
); ?>
</div>
</div>
<div class="row">
<div class="broker_hello">
<span class="username" style="text-transform:uppercase;">HI <?php echo esc_html($current_user->user_firstname); ?>
</span>
<span class="greating"> - How can we help?
</span>
</div>
</div>
</div>
</div>
</div>
</header>
</div>
<script>
function showSearch() {
jQuery(document).ready(function($) {
$("#seacrh_mobile").slideToggle();
if ($(".mobile_collapse").css('display') == 'block') {
$(".mobile_collapse").slideToggle();
}
if ($(".people_span").css('display') == 'block') {
// $(".people_span").css('margin-top',' 20px')
}
if ($(".people_span").css('display') != 'block') {
$(".people_span").delay(500).animate({
'width': 'toggle'
});
}
if ($("#seacrh_mobile").css('display') != 'block') {
// $(".people_span").css('margin-top',' -5%')
}
});
}
function toggle_mobile_menu() {
jQuery(document).ready(
function($) {
$(".mobile_collapse").slideToggle(300);
$("#mySidenav").removeClass('mySidenavOpen');
$(".people_span").removeClass('peopleOpen');
if ($("#seacrh_mobile").css('display') == 'block') {
$("#seacrh_mobile").slideToggle();
}
}
);
}
// Using jQuery.
jQuery(document).ready(
function($) {
$(function() {
$('.searchform').each(
function() {
$(this).find('input').keypress(
function(e) {
// Enter pressed?
if (e.which == 10 || e.which == 13) {
this.form.submit();
}
}
);
$(this).find('input[type=text]').attr("placeholder", "Search keyword");
// Why??
// $(this).find('input[type=submit]').hide();
}
);
});
}
);
</script>