PageRenderTime 54ms CodeModel.GetById 29ms RepoModel.GetById 0ms app.codeStats 0ms

/wp-content/themes/toolbox/header.php

https://bitbucket.org/lgorence/quickpress
PHP | 75 lines | 51 code | 10 blank | 14 comment | 7 complexity | 5b0b287fadab2af31f88e64aa8a701b3 MD5 | raw file
Possible License(s): GPL-2.0, LGPL-2.1, AGPL-1.0
  1. <?php
  2. /**
  3. * The Header for our theme.
  4. *
  5. * Displays all of the <head> section and everything up till <div id="main">
  6. *
  7. * @package Toolbox
  8. * @since Toolbox 0.1
  9. */
  10. ?><!DOCTYPE html>
  11. <!--[if IE 6]>
  12. <html id="ie6" <?php language_attributes(); ?>>
  13. <![endif]-->
  14. <!--[if IE 7]>
  15. <html id="ie7" <?php language_attributes(); ?>>
  16. <![endif]-->
  17. <!--[if IE 8]>
  18. <html id="ie8" <?php language_attributes(); ?>>
  19. <![endif]-->
  20. <!--[if !(IE 6) | !(IE 7) | !(IE 8) ]><!-->
  21. <html <?php language_attributes(); ?>>
  22. <!--<![endif]-->
  23. <head>
  24. <meta charset="<?php bloginfo( 'charset' ); ?>" />
  25. <meta name="viewport" content="width=device-width" />
  26. <title><?php
  27. /*
  28. * Print the <title> tag based on what is being viewed.
  29. */
  30. global $page, $paged;
  31. wp_title( '|', true, 'right' );
  32. // Add the blog name.
  33. bloginfo( 'name' );
  34. // Add the blog description for the home/front page.
  35. $site_description = get_bloginfo( 'description', 'display' );
  36. if ( $site_description && ( is_home() || is_front_page() ) )
  37. echo " | $site_description";
  38. // Add a page number if necessary:
  39. if ( $paged >= 2 || $page >= 2 )
  40. echo ' | ' . sprintf( __( 'Page %s', 'toolbox' ), max( $paged, $page ) );
  41. ?></title>
  42. <link rel="profile" href="http://gmpg.org/xfn/11" />
  43. <link rel="stylesheet" type="text/css" media="all" href="<?php bloginfo( 'stylesheet_url' ); ?>" />
  44. <?php if ( is_singular() && get_option( 'thread_comments' ) ) wp_enqueue_script( 'comment-reply' ); ?>
  45. <link rel="pingback" href="<?php bloginfo( 'pingback_url' ); ?>" />
  46. <!--[if lt IE 9]>
  47. <script src="<?php echo get_template_directory_uri(); ?>/js/html5.js" type="text/javascript"></script>
  48. <![endif]-->
  49. <?php wp_head(); ?>
  50. </head>
  51. <body <?php body_class(); ?>>
  52. <div id="page" class="hfeed">
  53. <?php do_action( 'before' ); ?>
  54. <header id="branding" role="banner">
  55. <hgroup>
  56. <h1 id="site-title"><a href="<?php echo home_url( '/' ); ?>" title="<?php echo esc_attr( get_bloginfo( 'name', 'display' ) ); ?>" rel="home"><?php bloginfo( 'name' ); ?></a></h1>
  57. <h2 id="site-description"><?php bloginfo( 'description' ); ?></h2>
  58. </hgroup>
  59. <nav id="access" role="navigation">
  60. <h1 class="assistive-text section-heading"><?php _e( 'Main menu', 'toolbox' ); ?></h1>
  61. <div class="skip-link screen-reader-text"><a href="#content" title="<?php esc_attr_e( 'Skip to content', 'toolbox' ); ?>"><?php _e( 'Skip to content', 'toolbox' ); ?></a></div>
  62. <?php wp_nav_menu( array( 'theme_location' => 'primary' ) ); ?>
  63. </nav><!-- #access -->
  64. </header><!-- #branding -->
  65. <div id="main">