-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathheader.php
37 lines (37 loc) · 1.22 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
<!DOCTYPE html>
<html lang="ja" <?php language_attributes(); ?>>
<head profile="http://gmpg.org/xfn/11">
<meta <?php echo 'charset='. bloginfo('charset'); ?> />
<meta content="" name="keywords" />
<meta content="" name="description" />
<meta content="" name="author" />
<?php if(is_category()): ?><?php elseif(is_archive()): ?>
<meta content="noindex,follow" name="robots" />
<?php elseif(is_tag()): ?>
<meta content="noindex,follow" name="robots" />
<?php endif; ?><title><?php
global $page, $paged;
if(is_front_page()):
bloginfo('name');
elseif(is_single()):
wp_title('');
elseif(is_page()):
wp_title('');
elseif(is_archive()):
wp_title('|',true,'right');
bloginfo('name');
elseif(is_search()):
wp_title('-',true,'right');
elseif(is_404()):
echo'404 - ';
bloginfo('name');
endif;
if($paged >= 2 || $page >= 2):
echo'-'.sprintf('%sページ',
max($paged,$page));
endif;
?></title>
<link <?php echo 'title='. bloginfo('name') .'RSS Feed'; echo 'href='. bloginfo('rss2_url'); ?>" rel="alternate" type="application/rss+xml />
<?php wp_head(); ?>
</head>
</html>