-
Notifications
You must be signed in to change notification settings - Fork 7
/
Copy pathheader-meta.php
46 lines (45 loc) · 1.37 KB
/
header-meta.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
<?php
/**
* Copyright (c) 2012 3g4k.com.
* All rights reserved.
* @package gkwp
* @author luofei614 <weibo.com/luofei614>
* @copyright 2012 3g4k.com.
*/
?><!DOCTYPE HTML>
<!--[if IE 6]>
<html id="ie6" <?php language_attributes(); ?>>
<![endif]-->
<!--[if IE 7]>
<html id="ie7" <?php language_attributes(); ?>>
<![endif]-->
<!--[if IE 8]>
<html id="ie8" <?php language_attributes(); ?>>
<![endif]-->
<!--[if !(IE 6) | !(IE 7) | !(IE 8) ]><!-->
<html <?php language_attributes(); ?>>
<!--<![endif]-->
<head>
<meta charset="<?php bloginfo( 'charset' ); ?>" />
<meta name="viewport" content="width=device-width" />
<title><?php
global $page, $paged;
wp_title( '|', true, 'right' );//文章标题
bloginfo( 'name' );//网站名称
$site_description = get_bloginfo( 'description', 'display' );//网站描述
if ( $site_description && ( is_home() || is_front_page() ) )
echo " | $site_description";
if ( $paged >= 2 || $page >= 2 )
echo ' | ' . sprintf( __( '第%s页', 'gkwp' ), max( $paged, $page ) );//第几页
?></title>
<link rel="pingback" href="<?php bloginfo( 'pingback_url' ); ?>" />
<?php
//加载css
gk_load_css();
wp_head();
//加载js
gk_load_js();
if ( is_singular() && get_option( 'thread_comments' ) ) wp_enqueue_script( 'comment-reply' );
?>
</head>
<body <?php body_class(); ?>>