Advertisement
Moslem1337

Untitled

Sep 11th, 2022
25
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.02 KB | None | 0 0
  1. <?php
  2. /**
  3. * The header for our theme
  4. *
  5. * This is the template that displays all of the <head> section and everything up until <div id="content">
  6. *
  7. * @link https://developer.wordpress.org/themes/basics/template-files/#template-partials
  8. *
  9. * @package PenNews
  10. */
  11.  
  12. ?><!DOCTYPE html>
  13. <html <?php language_attributes(); ?>>
  14. <head>
  15. <meta charset="<?php bloginfo( 'charset' ); ?>">
  16. <?php if( ! penci_get_theme_mod( 'penci_disable_reponsive' ) ): ?>
  17. <meta name="viewport" content="width=device-width, initial-scale=1">
  18. <?php endif; ?>
  19. <link rel="profile" href="http://gmpg.org/xfn/11">
  20. <?php wp_head(); ?>
  21. <style>
  22. a.custom-button.pencisc-button {
  23. background: transparent;
  24. color: #D3347B;
  25. border: 2px solid #D3347B;
  26. line-height: 36px;
  27. padding: 0 20px;
  28. font-size: 14px;
  29. font-weight: bold;
  30. }
  31. a.custom-button.pencisc-button:hover {
  32. background: #D3347B;
  33. color: #fff;
  34. border: 2px solid #D3347B;
  35. }
  36. a.custom-button.pencisc-button.pencisc-small {
  37. line-height: 28px;
  38. font-size: 12px;
  39. }
  40. a.custom-button.pencisc-button.pencisc-large {
  41. line-height: 46px;
  42. font-size: 18px;
  43. }
  44. </style>
  45. <script async src="https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js?client=ca-pub-4581602831169091"
  46. crossorigin="anonymous"></script>
  47. </head>
  48.  
  49. <body <?php body_class(); ?>>
  50.  
  51. <?php
  52. if ( penci_get_theme_mod( 'penci_after_body_tag' ) ) {
  53. echo do_shortcode( penci_get_theme_mod( 'penci_after_body_tag' ) );
  54. }
  55.  
  56.  
  57.  
  58.  
  59. $class_boxed = '';
  60. if( is_page_template( 'page-templates/layout-boxed.php' ) ) {
  61. $class_boxed = ' penci-enable-boxed';
  62. }elseif( ! is_page_template( 'page-templates/full-width.php' ) ) {
  63. if ( get_theme_mod( 'penci_body_boxed_layout' ) ) {
  64. $class_boxed = ' penci-enable-boxed';
  65. }
  66. }
  67. $nav_show = penci_get_theme_mod( 'penci_verttical_nav_show' );
  68. if( $nav_show ) {
  69. get_template_part( 'template-parts/menu-nav' );
  70.  
  71. $class_boxed .= ' penci-wrapper-boxed';
  72. }
  73.  
  74. ?>
  75. <div id="page" class="site<?php echo ( $class_boxed ); ?>">
  76. <?php
  77. $pennews_hide_header = false;
  78. if ( is_page() ) {
  79. $pennews_hide_header = get_post_meta( get_the_ID(), 'penci_hide_page_header', true );
  80. }
  81.  
  82. if( ! $pennews_hide_header ):
  83. do_action( 'penci_header_top' );
  84.  
  85. $header_layout = penci_get_setting( 'penci_header_layout' );
  86. if( 'header_s7' != $header_layout ){
  87. get_template_part( 'template-parts/topbar/topbar' );
  88. }
  89.  
  90. $class_trans_nav = '';
  91.  
  92. if( penci__header_tran() ){
  93. $class_trans_nav = ' penci-trans-nav';
  94. }
  95.  
  96. echo '<div class="site-header-wrapper' . $class_trans_nav . '">';
  97. get_template_part( 'template-parts/header/' . penci_get_setting( 'penci_header_layout' ) );
  98. echo '</div>';
  99.  
  100. if( ! $nav_show ) {
  101. get_template_part( 'template-parts/header/header_mobile' );
  102. }
  103. penci_render_google_adsense( 'penci_archive_ad_below_header' );
  104. get_template_part( 'template-parts/header/header-signup-form' );
  105. endif;
  106.  
  107. get_template_part( 'template-parts/header/page-header' );
  108. ?>
  109. <div id="content" class="site-content">
  110.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement