-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathheader.php
77 lines (76 loc) · 3.29 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
<!DOCTYPE html>
<html <?php language_attributes(); ?>>
<head>
<meta charset="<?php bloginfo('charset');?>" />
<title><?php
if (is_home()) {
bloginfo('name');
echo ' - ';
bloginfo('description');
} else {
wp_title(' - ', true, 'right');
bloginfo('name');
} ?>
</title>
<link rel="pingback" href="<?php bloginfo('pingback_url');?>" />
<link rel="alternate" type="application/rss+xml" title="訂閱 RSS 2.0" href="<?php bloginfo('rss2_url');?>" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<meta name="generator" content="WordPress" />
<?php wp_head(); ?>
<script src="<?php bloginfo('template_directory') ?>/framework/front/macho.js" type="text/javascript" /></script>
<script src="<?php bloginfo('template_directory') ?>/framework/front/base.js?ver=1.0" type="text/javascript" /></script>
<link rel="Shortcut Icon" type="image/x-icon" href="<?php the_option('favicon');?>" />
<link href="<?php bloginfo('template_directory') ?>/stylesheets/screen.css?ver=1.0" media="screen" rel="stylesheet" type="text/css" />
<link href="//netdna.bootstrapcdn.com/font-awesome/3.1.1/css/font-awesome.css" rel="stylesheet">
<!--[if lte IE 9]>
<script src="http://html5shiv.googlecode.com/svn/trunk/html5.js"></script>
<![endif]-->
<style type="text/css">
<?php if ( f_option('background_color') ){ $color = f_option('background_color'); } ?>
<?php if ( f_option('background_image') ){ $image = f_option('background_image'); } ?>
body { background: <?php if ( $color ){ echo $color; } ?> <?php if ( $image ){ echo "url('" . $image . "');"; } ?>}
<?php the_option('custom_css');?>
</style>
<?php the_option('custom_head'); ?>
</head>
<body>
<?php if( is_option('fb_appid') ): ?>
<div id="fb-root"></div>
<script>
(function(d, s, id) {
var js, fjs = d.getElementsByTagName(s)[0];
if (d.getElementById(id)) return;
js = d.createElement(s); js.id = id;
js.src = "//connect.facebook.net/zh_TW/all.js#xfbml=1&appId=<?php the_option('fb_appid');?>";
fjs.parentNode.insertBefore(js, fjs);
}(document, 'script', 'facebook-jssdk'));
</script>
<?php endif; ?>
<script type="text/javascript">
window.___gcfg = {
lang : 'zh-TW'
}; (function() {
var po = document.createElement('script');
po.type = 'text/javascript';
po.async = true;
po.src = 'https://apis.google.com/js/plusone.js';
var s = document.getElementsByTagName('script')[0];
s.parentNode.insertBefore(po, s);
})();
</script>
<div class="wrapper">
<div class="inner">
<header role="header" class="header">
<hgroup class="header-gp">
<?php if ( is_option( 'logo') ): ?>
<h1 class="header-logo"><a href="<?php bloginfo( 'url' ) ?>" title="<?php bloginfo( 'description' ) ?>"><img src="<?php the_option('logo') ?>" alt="<?php bloginfo( 'name' ) ?>"></a></h1>
<?php else: ?>
<h1 class="header-logo"><a href="<?php bloginfo( 'url' ) ?>" title="<?php bloginfo( 'description' ) ?>"><?php bloginfo( 'name' ) ?></a></h1>
<h2 class="header-description"><?php bloginfo( 'description' ) ?></h2>
<?php endif; ?>
</hgroup>
<div class="float-primarymenu">
<?php wp_nav_menu( array( 'menu_class' => 'nav', 'theme_location' => 'primary-menu' ) ); ?>
</div>
</header>
<div class="container">