This repository has been archived by the owner on Feb 2, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathheader.php
137 lines (123 loc) · 5.38 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
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
<?php
/**
* The header for our theme.
*
* Displays all of the <head> section and everything up till <div id="content">..<div class="row">
*
* @package nano-progga
*/
?><!DOCTYPE html>
<html <?php language_attributes(); ?> class="no-js">
<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(); ?>>
<!--[if lt IE 8]>
<p class="browserupgrade">You are using an <strong>outdated</strong> browser. Please <a href="http://browsehappy.com/">upgrade your browser</a> to improve your experience.</p>
<![endif]-->
<div id="page" class="hfeed site">
<a class="skip-link screen-reader-text" href="#content"><?php esc_html_e( 'Skip to content', 'nano-progga' ); ?></a>
<header id="masthead" class="site-header" role="banner">
<nav class="navbar navbar-default navbar-inverse nano-progga-nav" role="navigation">
<div class="container-fluid container1200">
<div class="navbar-header">
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target="#navbar-nano-progga-collapse">
<span class="sr-only">Toggle Navigation</span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
<?php
$img_id = cs_get_option('logo');
if( $img_id ): ?>
<a href="<?php echo esc_url( home_url( '/' ) ); ?>" class="navbar-brand" rel="home">
<?php $img_src = wp_get_attachment_image_src( $img_id, 'full' ); ?>
<img src="<?php echo esc_url( $img_src[0] ); ?>" alt="<?php bloginfo( 'name' ); ?>" width="40" height="40">
</a>
<?php endif; ?>
</div> <!-- /.navbar-header -->
<div id="navbar-nano-progga-collapse" class="collapse navbar-collapse">
<h1 class="site-title navbar-text"><a href="<?php echo esc_url( home_url( '/' ) ); ?>" rel="home"><?php bloginfo( 'name' ); ?></a></h1>
<h2 class="site-description sr-only"><?php bloginfo( 'description' ); ?></h2>
<?php wp_nav_menu( array(
'theme_location' => 'main_menu',
'menu' => 'primary',
'depth' => 2,
'container' => false,
'menu_class' => 'nav navbar-nav navbar-right',
'menu_id' => '',
'fallback_cb' => 'wp_bootstrap_navwalker::fallback',
'walker' => new wp_bootstrap_navwalker()
) );
?>
</div>
</div> <!-- /.container-fluid container1200 -->
</nav> <!-- /.navbar navbar-default -->
<div class="site-branding">
<div class="container-fluid container1200">
<?php
/**
* Breadcrumbs
* @since 3.0.0
*/
nano_progga_breadcrumbs(); ?>
<?php
if( ( cs_get_option('showseriesblog') && is_page_template('page-templates/blog.php') ) || is_home() ) :
/**
* Featured Series
* @since 3.0.0
*/
if( cs_get_option('showseries') ) :
?>
<section id="series-showcase" class="hidden-print">
<?php
$series_ids = array(); //default
$series_ids = cs_get_option('serieschoice');
if( $series_ids ) : ?>
<div class="row">
<div class="col-md-12">
<h2 class="inner-title"><span><?php _e( 'Popular Series', 'nano-progga' ); ?></span></h2>
</div> <!-- /.col-md-12 -->
<?php
foreach ( $series_ids as $series_id ) :
$featured_series = get_term_by( 'id', (int) $series_id, 'series' );
$img_src = nano_get_tax_meta_img_src( $series_id, 'series_cover', $size = 'medium' );
$series_link = get_term_link( (int) $series_id, 'series' ); ?>
<div class="col-sm-3 col-xs-6 series-block">
<a href="<?php echo esc_url( $series_link ); ?>">
<?php if( $img_src ) : ?>
<img src="<?php echo esc_url( $img_src ); ?>" alt="<?php echo esc_attr( $featured_series->name ); ?>" width="270" height="118">
<div class="image-hover">
<div class="behave-table">
<div class="behave-table-cell expand-icon">
<h3><?php echo esc_html( $featured_series->name ); ?></h3>
</div>
</div>
</div>
<?php else : ?>
<h3 class="text-center"><?php echo esc_html( $featured_series->name ); ?></h3>
<?php endif; ?>
</a>
</div> <!-- /.col-sm-3 col-xs-6 -->
<?php
endforeach;
?>
</div> <!-- /.row -->
<hr class="dark">
<?php
endif;
?>
</section> <!-- /#series-showcase -->
<?php
endif; //showseries
endif; //is_home() ?>
</div> <!-- /.container-fluid container1200 -->
</div> <!-- .site-branding -->
</header><!-- #masthead -->
<div id="content" class="site-content">
<div class="container-fluid container1200">
<div class="row">