-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathheader.php
61 lines (50 loc) · 2.58 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
<?php if (!defined('__TYPECHO_ROOT_DIR__')) exit; ?>
<!DOCTYPE HTML>
<html lang="zh-CN">
<head>
<meta charset="<?php $this->options->charset(); ?>">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="renderer" content="webkit">
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
<title><?php $this->archiveTitle(array(
'category' => _t('分类 %s 下的文章'),
'search' => _t('包含关键字 %s 的文章'),
'tag' => _t('标签 %s 下的文章'),
'author' => _t('%s 发布的文章')
), '', ' - '); ?><?php $this->options->title(); ?></title>
<link rel="shortcut icon" href="<?php if ($this->options->favicon): $this->options->favicon();
else: $this->options->themeUrl('assets/img/favicon.ico');endif; ?>">
<link rel="stylesheet" href="<?php $this->options->themeUrl('assets/css/style.css'); ?>">
<link href="//cdn.bootcss.com/font-awesome/5.7.0/css/fontawesome.min.css" rel="stylesheet">
<!--[if lt IE 9]>
<script src="//cdn.bootcss.com/html5shiv/r29/html5.min.js"></script>
<script src="//cdn.bootcss.com/respond.js/1.4.1/respond.min.js"></script>
<![endif]-->
<?php $this->header(); ?>
</head>
<body>
<!--[IE 8]>
<div class="browsehappy" role="dialog"><?php _e('当前网页 <strong>不支持</strong> 你正在使用的浏览器. 为了正常的访问, 请升级你的浏览器</a>'); ?>.
</div>
<![endif]-->
<div class="wrap">
<header>
<a href="<?php $this->options->siteUrl(); ?>" class="logo-link">
<img src="<?php if ($this->options->logo): $this->options->logo(); else: $this->options->themeUrl('assets/img/logo.png');endif; ?>">
</a>
<li class="nav-list-item">
<a<?php if($this->is('index')): ?> class="nav-list-link active"<?php endif; ?> href="<?php $this->options->siteUrl(); ?>"><?php _e('首页'); ?></a>
</li>
<?php while ($cats->next()): ?>
<li class="nav-list-item">
<a <?php if($this->is('category', $cats->slug)): ?>class="nav-list-link active"<?php endif; ?> href="<?php $cats->permalink(); ?>"><?php $cats->name(); ?></a>
</li>
<?php endwhile; ?>
<?php $this->widget('Widget_Contents_Page_List')->to($pages); ?>
<?php while($pages->next()): ?>
<li class="nav-list-item">
<a <?php if($this->is('page', $pages->slug)): ?>class="nav-list-link active"<?php endif; ?> href="<?php $pages->permalink(); ?>"><?php $pages->title(); ?></a>
</li>
<?php endwhile; ?>
</header>
<section class="container">