Rev 27 | Details | Compare with Previous | Last modification | View Log | RSS feed
Rev | Author | Line No. | Line |
---|---|---|---|
3 | iacchi | 1 | <?php |
2 | /* |
||
3 | * The Header for our theme. |
||
4 | * |
||
5 | * Displays all of the <head> section and the main header, |
||
6 | * up till <div id="main">, the central div. |
||
7 | */ |
||
8 | ?> |
||
9 | <!DOCTYPE html> |
||
10 | <html <?php language_attributes(); ?>> |
||
11 | <head> |
||
12 | <meta http-equiv="Content-Type" content="<?php bloginfo('html_type'); ?>; charset=<?php bloginfo('charset'); ?>" /> |
||
13 | <title> |
||
14 | <?php |
||
15 | // Print the <title> tag based on what is being viewed. |
||
16 | global $page, $paged; |
||
17 | |||
18 | wp_title('-', true, 'right'); |
||
19 | |||
20 | // Add a page number if necessary: |
||
21 | if ($paged >= 2 || $page >= 2) |
||
27 | iacchi | 22 | echo sprintf(__('Page %s', 'zendark'), max($paged, $page)).' – '; |
3 | iacchi | 23 | |
24 | // Add the blog name. |
||
25 | bloginfo('name'); |
||
26 | ?> |
||
27 | </title> |
||
28 | <link rel="profile" href="http://gmpg.org/xfn/11" /> |
||
29 | <link rel="icon" href="<?php echo get_template_directory_uri(); ?>/images/favicon.png" type="image/png" /> |
||
30 | <?php |
||
31 | /* Select a different stylesheet with sidebar on the |
||
32 | * left when loading right-page template |
||
33 | */ |
||
34 | if (is_page_template('right-page.php') || is_page_template('zenphoto-page.php')) { ?> |
||
35 | <link rel="stylesheet" type="text/css" media="all" href="<?php echo get_template_directory_uri(); ?>/right-style.css" /> |
||
36 | <?php } |
||
37 | else { ?> |
||
38 | <link rel="stylesheet" type="text/css" media="all" href="<?php bloginfo('stylesheet_url'); ?>" /> |
||
39 | <?php } ?> |
||
35 | iacchi | 40 | <link href="http://fonts.googleapis.com/css?family=Open+Sans:400,400italic,700,700italic|Droid+Sans+Mono" rel="stylesheet" type="text/css"> |
3 | iacchi | 41 | <link rel="pingback" href="<?php bloginfo( 'pingback_url' ); ?>" /> |
42 | <!--[if lt IE 9]> |
||
43 | <script src="<?php echo get_template_directory_uri(); ?>/js/html5.js" type="text/javascript"></script> |
||
44 | <![endif]--> |
||
45 | <?php |
||
46 | /* We add some JavaScript to pages with the comment form |
||
47 | * to support sites with threaded comments (when in use). |
||
48 | */ |
||
49 | if (is_singular() && get_option('thread_comments')) |
||
50 | wp_enqueue_script('comment-reply'); |
||
51 | |||
52 | /* Always have wp_head() just before the closing </head> |
||
53 | * tag of your theme, or you will break many plugins, which |
||
54 | * generally use this hook to add elements to <head> such |
||
55 | * as styles, scripts, and meta tags. |
||
56 | */ |
||
57 | wp_head(); |
||
58 | ?> |
||
59 | </head> |
||
60 | |||
61 | <body <?php body_class(); ?>> |
||
62 | <div id="page"> |
||
63 | |||
64 | <header id="main-header"> |
||
65 | <hgroup> |
||
66 | <h1 id="site-title"><a href="<?php echo esc_url(home_url('/')); ?>" title="<?php echo esc_attr(get_bloginfo('name', 'display')); ?>"><?php bloginfo('name'); ?></a></h1> |
||
67 | <h2 id="site-description"><?php bloginfo('description'); ?></h2> |
||
68 | </hgroup> |
||
69 | <nav id="main-menu"> |
||
70 | <?php |
||
71 | /* Our navigation menu. If one isn't filled out, wp_nav_menu falls |
||
72 | * back to wp_page_menu. The menu assiged to the primary position is |
||
73 | * the one used. If none is assigned, the menu with the lowest ID is used. |
||
74 | */ |
||
75 | wp_nav_menu(array('theme_location' => 'primary', 'depth' => 1)); |
||
76 | ?> |
||
27 | iacchi | 77 | <div id="menu-title"><h1><?php if (is_page()) { echo get_the_title(zendark_get_root_parent(get_the_ID())); } else { _e('Blog', 'zendark'); } ?></h1></div> |
3 | iacchi | 78 | </nav> |
79 | </header><!-- #main-header --> |
||
80 | |||
81 | <div id="main"> |