PageRenderTime 43ms CodeModel.GetById 16ms RepoModel.GetById 0ms app.codeStats 0ms

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

https://github.com/mattyws/InfocorpSite
PHP | 118 lines | 80 code | 23 blank | 15 comment | 6 complexity | b0e132b1d6981c8cdda4a58cfce3af4b MD5 | raw file
Possible License(s): GPL-2.0, GPL-3.0, LGPL-2.1
  1. <?php
  2. // Exit if accessed directly
  3. if( !defined( 'ABSPATH' ) ) {
  4. exit;
  5. }
  6. /**
  7. * Header Template
  8. *
  9. *
  10. * @file header.php
  11. * @package Responsive
  12. * @author Emil Uzelac
  13. * @copyright 2003 - 2014 CyberChimps
  14. * @license license.txt
  15. * @version Release: 1.3
  16. * @filesource wp-content/themes/responsive/header.php
  17. * @link http://codex.wordpress.org/Theme_Development#Document_Head_.28header.php.29
  18. * @since available since Release 1.0
  19. */
  20. ?>
  21. <!doctype html>
  22. <!--[if !IE]>
  23. <html class="no-js non-ie" <?php language_attributes(); ?>> <![endif]-->
  24. <!--[if IE 7 ]>
  25. <html class="no-js ie7" <?php language_attributes(); ?>> <![endif]-->
  26. <!--[if IE 8 ]>
  27. <html class="no-js ie8" <?php language_attributes(); ?>> <![endif]-->
  28. <!--[if IE 9 ]>
  29. <html class="no-js ie9" <?php language_attributes(); ?>> <![endif]-->
  30. <!--[if gt IE 9]><!-->
  31. <html class="no-js" <?php language_attributes(); ?>> <!--<![endif]-->
  32. <head>
  33. <meta charset="<?php bloginfo( 'charset' ); ?>"/>
  34. <meta name="viewport" content="width=device-width, initial-scale=1.0">
  35. <title><?php wp_title( '&#124;', true, 'right' ); ?></title>
  36. <link rel="profile" href="http://gmpg.org/xfn/11"/>
  37. <link rel="pingback" href="<?php bloginfo( 'pingback_url' ); ?>"/>
  38. <?php wp_head(); ?>
  39. </head>
  40. <body <?php body_class(); ?>>
  41. <?php responsive_container(); // before container hook ?>
  42. <div id="container" class="hfeed">
  43. <?php responsive_header(); // before header hook ?>
  44. <div class="skip-container cf">
  45. <a class="skip-link screen-reader-text focusable" href="#main"><?php _e( '&darr; Skip to Main Content', 'responsive' ); ?></a>
  46. </div><!-- .skip-container -->
  47. <div id="header">
  48. <?php responsive_header_top(); // before header content hook ?>
  49. <?php if( has_nav_menu( 'top-menu', 'responsive' ) ) { ?>
  50. <?php wp_nav_menu( array(
  51. 'container' => '',
  52. 'fallback_cb' => false,
  53. 'menu_class' => 'top-menu',
  54. 'theme_location' => 'top-menu'
  55. )
  56. );
  57. ?>
  58. <?php } ?>
  59. <?php responsive_in_header(); // header hook ?>
  60. <?php if( get_header_image() != '' ) : ?>
  61. <div id="logo">
  62. <a href="<?php echo home_url( '/' ); ?>"><img src="<?php header_image(); ?>" width="<?php echo get_custom_header()->width; ?>" height="<?php echo get_custom_header()->height; ?>" alt="<?php bloginfo( 'name' ); ?>"/></a>
  63. </div><!-- end of #logo -->
  64. <?php endif; // header image was removed ?>
  65. <?php if( !get_header_image() ) : ?>
  66. <div id="logo">
  67. <span class="site-name"><a href="<?php echo home_url( '/' ); ?>" title="<?php echo esc_attr( get_bloginfo( 'name', 'display' ) ); ?>" rel="home"><?php bloginfo( 'name' ); ?></a></span>
  68. <span class="site-description"><?php bloginfo( 'description' ); ?></span>
  69. </div><!-- end of #logo -->
  70. <?php endif; // header image was removed (again) ?>
  71. <?php get_sidebar( 'top' ); ?>
  72. <?php wp_nav_menu( array(
  73. 'container' => 'div',
  74. 'container_class' => 'main-nav',
  75. 'fallback_cb' => 'responsive_fallback_menu',
  76. 'theme_location' => 'header-menu'
  77. )
  78. );
  79. ?>
  80. <?php if( has_nav_menu( 'sub-header-menu', 'responsive' ) ) { ?>
  81. <?php wp_nav_menu( array(
  82. 'container' => '',
  83. 'menu_class' => 'sub-header-menu',
  84. 'theme_location' => 'sub-header-menu'
  85. )
  86. );
  87. ?>
  88. <?php } ?>
  89. <?php responsive_header_bottom(); // after header content hook ?>
  90. </div><!-- end of #header -->
  91. <?php responsive_header_end(); // after header container hook ?>
  92. <?php responsive_wrapper(); // before wrapper container hook ?>
  93. <div id="wrapper" class="clearfix">
  94. <?php responsive_wrapper_top(); // before wrapper content hook ?>
  95. <?php responsive_in_wrapper(); // wrapper hook ?>