-
Notifications
You must be signed in to change notification settings - Fork 8
/
Copy pathheader.php
executable file
·79 lines (78 loc) · 2.33 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
<!DOCTYPE html>
<!--[if IE 9]><html class="lt-ie10" lang="en" > <![endif]-->
<!--[if IE 10]><html class="ie10" lang="en" > <![endif]-->
<html <?php language_attributes(); ?>>
<!--<![endif]-->
<head>
<meta charset="<?php bloginfo( 'charset' ); ?>">
<meta name="viewport" content="width=device-width">
<title><?php wp_title( '|', true, 'right' ); ?></title>
<link rel="profile" href="http://gmpg.org/xfn/11">
<link rel="pingback" href="<?php bloginfo( 'pingback_url' ); ?>">
<?php wp_head(); ?>
<?php if ( has_post_thumbnail() ) : ?>
<style>
.main-img{
background-image: url(
<?php echo wp_get_attachment_url( get_post_thumbnail_id() ); ?>
);
background-repeat: repeat-x;
background-position: center center fixed;
-webkit-background-size: cover;
-moz-background-size: cover;
-o-background-size: cover;
background-size: cover;
}
</style>
<?php endif; ?>
</head>
<body <?php body_class(); ?>>
<div class="contain-to-grid">
<nav class="top-bar" data-topbar="">
<ul class="title-area">
<li class="name">
<span class="icon-wpd02"></span>
<h1>
<a href="<?php echo esc_url( home_url( '/' ) ); ?>" rel="home">
<?php bloginfo( 'name' ); ?>
</a>
</h1>
</li>
<li class="toggle-topbar menu-icon">
<a href=""><span>Menu</span></a>
</li>
</ul>
<section class="top-bar-section">
<!-- カスタムナビゲーションの読み込み -->
<?php wp_nav_menu (array(
'theme_location'=>'mainmenu', // 利用するナビゲーション
'container' => false,
'menu_class' => 'right', // 付与するclass
'menu_id' => 'top', // 付与するid
'echo' => true,
'fallback_cb' => 'wp_page_menu',
'after' => '<li class="divider"></li>',
'items_wrap' => '<ul id="%1$s" class="%2$s"><li class="divider"></li>%3$s</ul>',
)); ?>
</section>
</nav>
</div>
<div class="main-img <?php $author = get_userdata($post->post_author); echo $author->display_name; ?>
">
<div class="row">
<div class="large-12 columns text-center">
<?php
if(get_field('catchcopy'))
{
echo '<h1>' . get_field('catchcopy') . '</h1>';
}
?>
<?php
if(get_field('subcopy'))
{
echo '<h3>' . get_field('subcopy') . '</h3>';
}
?>
</div>
</div>
</div>