Advertisement
mdixon

header.php

Dec 21st, 2012
115
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 7.96 KB | None | 0 0
  1. <?php
  2. /**
  3.  * The Header for our theme.
  4.  *
  5.  * Displays all of the <head> section and everything up till <div id="content-main">
  6.  *
  7.  * @package Graphene
  8.  * @since graphene 1.0
  9.  */
  10. global $graphene_settings;
  11. ?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
  12. <html xmlns="http://www.w3.org/1999/xhtml" <?php language_attributes(); ?>>
  13. <head profile="http://gmpg.org/xfn/11">
  14.     <meta http-equiv="Content-Type" content="<?php bloginfo( 'html_type' ); ?>; charset=<?php bloginfo( 'charset' ); ?>" />
  15.     <meta http-equiv="X-UA-Compatible" content="IE=8" />
  16.     <title><?php wp_title( '' ); ?></title>
  17.     <link rel="pingback" href="<?php bloginfo( 'pingback_url' ); ?>" />
  18.    
  19.     <?php wp_head(); ?>
  20.    
  21. </head>
  22.  
  23. <!--BODY-->
  24.  
  25. <body <?php body_class(); ?>>
  26.  
  27. <?php if ( !get_theme_mod( 'background_image', false) && !get_theme_mod( 'background_color', false) ) : ?>
  28. <div class="bg-gradient">
  29. <?php endif; ?>
  30.  
  31. <!--CONTAINER-->
  32.  
  33. <?php do_action( 'graphene_container_before' ); ?>
  34.  
  35. <div id="container" class="container_16">
  36.    
  37.     <?php if ( $graphene_settings['hide_top_bar'] != true) : ?>
  38.    
  39. <!--TOP BAR-->
  40.    
  41.         <div id="top-bar">
  42.                 <?php do_action( 'graphene_before_feed_icon' ); ?>
  43.                
  44. <!--TOOK OUT GRAPHENE SOCIAL PROFILES-->
  45.                
  46. <!--TOP SEARCH-->
  47.  
  48.             <?php
  49.             /**
  50.              * Retrieves our custom search form.
  51.              */
  52.             ?>
  53.             <?php if ( ( $search_box_location = $graphene_settings['search_box_location'] ) && $search_box_location == 'top_bar' || $search_box_location == '' ) : ?>
  54.            
  55.                 <div id="top_search" class="grid_4">
  56.                     <?php get_search_form(); ?>
  57.                     <?php do_action( 'graphene_top_search' ); ?>
  58.                 </div>
  59.                 <?php endif; ?>
  60.  
  61. <!--END TOP SEARCH-->
  62.  
  63. <!--LOG IN-->  
  64.            
  65.             <div id="log_in">
  66.             <a href="http://www.walkinghorseowners.com/wp-login.php?redirect_to=http%3A%2F%2Fwalkinghorseowners.com%2Fwp-admin%2F&reauth=1"><img src="<?php echo get_stylesheet_directory_uri();?>/images/button_member-log-in.png" alt="" /></a>
  67.             </div> 
  68.            
  69. <!--END LOG IN-->
  70.  
  71. <!--WHOA SOCIAL ICONS-->
  72.  
  73.             <div id="social_icons">
  74.             <ul>
  75.             <li><a href="http://www.facebook.com/pages/Walking-Horse-Owners-Association/331617650187038" onclick="target='_blank'"><img src="<?php echo get_stylesheet_directory_uri();?>/images/facebook.png" alt="" /></a></li>
  76.             <li><a href="http://www.twitter.com/walkinghorseown" onclick="target='_blank'"><img src="<?php echo get_stylesheet_directory_uri();?>/images/twitter.png" alt="" /></a></li>
  77.             <li><a href="http://www.youtube.com/WalkingHorseOwners" onclick="target='_blank'"><img src="<?php echo get_stylesheet_directory_uri();?>/images/youtube.png" alt="" /></a></li>
  78.             <li><a href="http://fusion.google.com/add?source=atgs&feedurl=http://walkinghorseowners.com/feed/"><img src="<?php echo get_stylesheet_directory_uri();?>/images/rss.png" alt="" /></a></li>
  79.             </ul>
  80.             </div>
  81.  
  82. <!--END WHOA SOCIAL ICONS-->
  83.            
  84.         <?php do_action( 'graphene_top_bar' ); ?>
  85.         </div>
  86.        
  87.     <?php endif; ?>
  88.  
  89. <!--END TOP BAR-->
  90.  
  91.     <?php
  92.         $post_id = ( $post ) ? $post->ID : false;
  93.         $header_img = apply_filters( 'graphene_header_image', graphene_get_header_image( $post_id ) );
  94.  
  95.         /* Check if the page uses SSL and change HTTP to HTTPS if true */
  96.         if ( is_ssl() && stripos( $header_img, 'https' ) === false ) {
  97.             $header_img = str_replace( 'http', 'https', $header_img );
  98.         }
  99.     ?>
  100.    
  101. <!--HEADER-->
  102.  
  103.     <div id="header">
  104.        
  105.         <?php
  106.             $header_img = '<img src="' . $header_img . '" alt="" class="header-img" />';
  107.             if ( ! is_front_page() && $graphene_settings['link_header_img'] ) {
  108.                 $header_img_tag = '<a href="' . apply_filters( 'graphene_header_link' , home_url() ) . '" id="header_img_link" title="' . esc_attr__( 'Go back to the front page', 'graphene' ) . '">';
  109.                 $header_img_tag .= $header_img;
  110.                 $header_img_tag .= '</a>';
  111.                
  112.                 $header_img = $header_img_tag;
  113.             }
  114.             echo $header_img;
  115.         ?>
  116.                    
  117.         <?php /* Header widget area */
  118.         if ( $graphene_settings['enable_header_widget'] && is_active_sidebar( 'header-widget-area' ) ) {
  119.             echo '<div class="header-widget">';
  120.             dynamic_sidebar( 'header-widget-area' );
  121.             echo '</div>';
  122.         }
  123.         ?>
  124.        
  125.         <?php /* The site title and description */
  126.         if ( ! in_array( get_theme_mod( 'header_textcolor', HEADER_TEXTCOLOR ), array( 'blank', '' ) ) ) :
  127.             if ( is_singular() && ! is_front_page() ) {
  128.                 $title_tag = 'h2';
  129.                 $desc_tag = 'h3';
  130.             } else {
  131.                 $title_tag = 'h1';
  132.                 $desc_tag = 'h2';
  133.             }
  134.             ?>
  135.             <?php echo "<$title_tag class=\"header_title push_1 grid_15\">"; ?>
  136.                 <?php if ( ! is_front_page() ) : ?><a href="<?php echo apply_filters( 'graphene_header_link' , home_url() ); ?>" title="<?php esc_attr_e( 'Go back to the front page', 'graphene' ); ?>"><?php endif; ?>
  137.                     <?php bloginfo( 'name' ); ?>
  138.                 <?php if ( ! is_front_page() ) : ?></a><?php endif; ?>
  139.             <?php echo "</$title_tag>"; ?>
  140.            
  141.             <?php echo "<$desc_tag class=\"header_desc push_1 grid_15\">"; ?>
  142.                 <?php bloginfo( 'description' ); ?>
  143.             <?php echo "</$desc_tag>"; ?>
  144.         <?php endif; ?>
  145.        
  146.         <?php do_action( 'graphene_header' ); ?>
  147.     </div>
  148.    
  149. <!--END HEADER-->
  150.    
  151. <!--NAVIGATION-->
  152.    
  153.     <div id="nav">
  154.         <?php /* The navigation menu */ ?>
  155.        
  156. <!--HEADER MENU WRAP-->
  157.         <div id="header-menu-wrap" class="clearfix">
  158.             <?php
  159.             /* Header menu */
  160.             $args = array(
  161.                 'container' => '',
  162.                 'menu_id' => 'header-menu',
  163.                 'menu_class' => graphene_get_menu_class( 'menu clearfix' ),
  164.                 'fallback_cb' => 'graphene_default_menu',
  165.                 'depth' => 5,
  166.                 'theme_location' => 'Header Menu',
  167.             );
  168.             if ( ! $graphene_settings['disable_menu_desc'] )
  169.                 $args = array_merge( $args, array( 'walker' => new Graphene_Description_Walker() ) );
  170.                
  171.             wp_nav_menu( apply_filters( 'graphene_header_menu_args', $args ) ); ?>
  172.            
  173.             <div class="clear"></div>
  174.            
  175. <!--REMOVED NAV SEARCH BAR OPTION-->
  176.            
  177.             <?php do_action( 'graphene_header_menu' ); ?>
  178.        
  179.         </div>
  180. <!--END HEADER MENU WRAP-->
  181.        
  182.         <?php
  183.         /* Secondary menu */
  184.         $args = array(
  185.             'container' => 'div',
  186.             'container_id' => 'secondary-menu-wrap',
  187.             'container_class' => 'clearfix',
  188.             'menu_id' => 'secondary-menu',
  189.             'menu_class' => 'menu clearfix',
  190.             'fallback_cb' => 'none',
  191.             'depth' => 5,
  192.             'theme_location' => 'secondary-menu',
  193.         );
  194.         wp_nav_menu( apply_filters( 'graphene_secondary_menu_args', $args ) );
  195.         ?>
  196.                
  197.         <div class="menu-bottom-shadow">&nbsp;</div>
  198.  
  199.  
  200.         <?php do_action( 'graphene_top_menu' ); ?>
  201.  
  202.     </div>
  203.    
  204. <!--END NAVIGATION-->
  205.    
  206. <!--CONTENT-->
  207.    
  208.         <?php do_action( 'graphene_before_content' ); ?>
  209.  
  210.     <div id="content" class="clearfix hfeed">
  211.         <?php do_action( 'graphene_before_content-main' ); ?>
  212.        
  213.         <?php
  214.        
  215.             /* Sidebar2 on the left side? */
  216.             if ( in_array( graphene_column_mode(), array( 'three_col_right', 'three_col_center', 'two_col_right' ) ) ){
  217.                 get_sidebar( 'two' );
  218.             }
  219.            
  220.             /* Sidebar1 on the left side? */            
  221.             if ( in_array( graphene_column_mode(), array( 'three_col_right' ) ) ){
  222.                 get_sidebar();                
  223.             }
  224.        
  225.         ?>
  226.        
  227. <!--CONTENT-MAIN-->
  228.        
  229.         <div id="content-main" <?php graphene_grid( 'clearfix', 16, 11, 8 ); ?>>
  230.         <?php do_action( 'graphene_top_content' ); ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement