mh_magazine_lite_custom_header

The MH Magazine lite mh magazine lite custom header function.

Description

mh_magazine_lite_custom_header(); 

Usage

  1. if ( !function_exists( 'mh_magazine_lite_custom_header' ) ) { 
  2. require_once '/includes/mh-custom-functions.php'; 
  3.  
  4.  
  5. // NOTICE! Understand what this does before running. 
  6. $result = mh_magazine_lite_custom_header(); 
  7.  

Defined (1)

The function is defined in the following location(s).

/includes/mh-custom-functions.php  
  1. function mh_magazine_lite_custom_header() { 
  2. echo '<div class="mh-custom-header clearfix">' . "\n"; 
  3. if (get_header_image()) { 
  4. echo '<a class="mh-header-image-link" href="' . esc_url(home_url('/')) . '" title="' . esc_attr(get_bloginfo('name')) . '" rel="home">' . "\n"; 
  5. echo '<img class="mh-header-image" src="' . esc_url(get_header_image()) . '" height="' . esc_attr(get_custom_header()->height) . '" width="' . esc_attr(get_custom_header()->width) . '" alt="' . esc_attr(get_bloginfo('name')) . '" />' . "\n"; 
  6. echo '</a>' . "\n"; 
  7. if (function_exists('has_custom_logo') && has_custom_logo() || display_header_text()) { 
  8. echo '<div class="mh-site-identity">' . "\n"; 
  9. echo '<div class="mh-site-logo" role="banner" itemscope="itemscope" itemtype="http://schema.org/Brand">' . "\n"; 
  10. if (function_exists('the_custom_logo')) { 
  11. the_custom_logo(); 
  12. if (display_header_text()) { 
  13. if (get_header_textcolor() != get_theme_support('custom-header', 'default-text-color')) { 
  14. echo '<style type="text/css" id="mh-header-css">'; 
  15. echo '.mh-header-title, .mh-header-tagline { color: #' . esc_attr(get_header_textcolor()) . '; }'; 
  16. echo '</style>' . "\n"; 
  17. echo '<div class="mh-header-text">' . "\n"; 
  18. if (is_front_page()) { 
  19. $header_title_before = '<h1 class="mh-header-title">'; 
  20. $header_title_after = '</h1>' . "\n"; 
  21. $header_tagline_before = '<h2 class="mh-header-tagline">'; 
  22. $header_tagline_after = '</h2>' . "\n"; 
  23. } else { 
  24. $header_title_before = '<h2 class="mh-header-title">'; 
  25. $header_title_after = '</h2>' . "\n"; 
  26. $header_tagline_before = '<h3 class="mh-header-tagline">'; 
  27. $header_tagline_after = '</h3>' . "\n"; 
  28. echo '<a class="mh-header-text-link" href="' . esc_url(home_url('/')) . '" title="' . esc_attr(get_bloginfo('name')) . '" rel="home">' . "\n"; 
  29. if (get_bloginfo('name')) { 
  30. echo $header_title_before . esc_attr(get_bloginfo('name')) . $header_title_after; 
  31. if (get_bloginfo('description')) { 
  32. echo $header_tagline_before . esc_attr(get_bloginfo('description')) . $header_tagline_after; 
  33. echo '</a>' . "\n"; 
  34. echo '</div>' . "\n"; 
  35. echo '</div>' . "\n"; 
  36. echo '</div>' . "\n"; 
  37. echo '</div>' . "\n";