Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <!doctype html >
- <!--[if IE 8]> <html class="ie8" lang="en"> <![endif]-->
- <!--[if IE 9]> <html class="ie9" lang="en"> <![endif]-->
- <!--[if gt IE 8]><!--> <html <?php language_attributes(); ?>> <!--<![endif]-->
- <head>
- <title><?php wp_title('|', true, 'right'); ?></title>
- <meta charset="<?php bloginfo( 'charset' );?>" />
- <meta name="viewport" content="width=device-width, initial-scale=1.0">
- <link rel="pingback" href="<?php bloginfo( 'pingback_url' ); ?>" />
- <?php
- wp_head(); /** we hook up in wp_booster @see td_wp_booster_functions::hook_wp_head */
- ?>
- </head>
- <body <?php body_class() ?> itemscope="itemscope" itemtype="<?php echo td_global::$http_or_https?>://schema.org/WebPage">
- <?php /* scroll to top */?>
- <div class="td-scroll-up"><i class="td-icon-menu-up"></i></div>
- <?php locate_template('parts/menu-mobile.php', true);?>
- <?php locate_template('parts/search.php', true);?>
- <style>
- @media (max-width: 767px) {
- .td-header-desktop-wrap {
- display: none;
- }
- }
- @media (min-width: 767px) {
- .td-header-mobile-wrap {
- display: none;
- }
- }
- .td-main-page-wrap{
- padding-top:0!important;
- }
- </style>
- <div id="td-outer-wrap" class="td-theme-wrap">
- <?php //this is closing in the footer.php file ?>
- <?php
- if ( td_util::tdc_is_live_editor_iframe() || ( ! td_util::is_template_header() && ! td_util::is_no_header() ) ) {
- $hide_class = '';
- if ( td_util::is_template_header() || td_util::is_no_header() ) {
- $hide_class = 'tdc-zone-invisible';
- }
- ?>
- <div class="tdc-header-wrap <?php echo $hide_class ?>">
- <?php
- /*
- * loads the header template set in Theme Panel -> Header area
- * the template files are located in ../parts/header
- */
- td_api_header_style::show_header();
- ?>
- </div>
- <?php
- }
- if ( td_util::tdc_is_live_editor_iframe() || td_util::is_template_header() ) {
- $tdc_header_template_content = td_util::get_header_template_content();
- $hide_class = '';
- ?>
- <div class="td-header-template-wrap" style="position: relative">
- <?php
- if ( empty( $tdc_header_template_content['tdc_header_mobile'] ) ) {
- $shortcode = '[tdc_zone type="tdc_header_mobile"][vc_row][vc_column][/vc_column][/vc_row][/tdc_zone]';
- $hide_class = 'tdc-zone-invisible';
- } else {
- $shortcode = $tdc_header_template_content['tdc_header_mobile'];
- }
- ?>
- <div class="td-header-mobile-wrap <?php echo $hide_class ?>">
- <?php echo do_shortcode( $shortcode ) ?>
- </div>
- <?php
- if ( empty( $tdc_header_template_content['tdc_header_mobile_sticky'] ) ) {
- $shortcode = '[tdc_zone type="tdc_header_mobile_sticky"][vc_row][vc_column][/vc_column][/vc_row][/tdc_zone]';
- } else {
- $shortcode = $tdc_header_template_content['tdc_header_mobile_sticky'];
- }
- ?>
- <div class="td-header-mobile-sticky-wrap tdc-zone-sticky-invisible tdc-zone-sticky-inactive" style="display: none">
- <?php echo do_shortcode( $shortcode ) ?>
- </div>
- <?php
- $hide_class = '';
- if ( empty( $tdc_header_template_content['tdc_header_desktop'] ) ) {
- $shortcode = '[tdc_zone type="tdc_header_desktop"][vc_row][vc_column][/vc_column][/vc_row][/tdc_zone]';
- $hide_class = 'tdc-zone-invisible';
- } else {
- $shortcode = $tdc_header_template_content['tdc_header_desktop'];
- }
- ?>
- <div class="td-header-desktop-wrap <?php echo $hide_class ?>">
- <?php echo do_shortcode( $shortcode ) ?>
- </div>
- <?php
- if ( empty( $tdc_header_template_content['tdc_header_desktop_sticky'] ) ) {
- $shortcode = '[tdc_zone type="tdc_header_desktop_sticky"][vc_row][vc_column][/vc_column][/vc_row][/tdc_zone]';
- } else {
- $shortcode = $tdc_header_template_content['tdc_header_desktop_sticky'];
- }
- ?>
- <div class="td-header-desktop-sticky-wrap tdc-zone-sticky-invisible tdc-zone-sticky-inactive" style="display: none">
- <?php echo do_shortcode( $shortcode ) ?>
- </div>
- </div>
- <?php
- }
- ?>
- <?php
- do_action('td_wp_booster_after_header'); //used by unique articles
- //set the template id, used to get the template specific settings
- $template_id = 'page';
- $loop_sidebar_position = td_util::get_option('tds_' . $template_id . '_sidebar_pos'); //sidebar right is default (empty)
- //get theme panel variable for page comments side wide
- $td_enable_or_disable_page_comments = td_util::get_option('tds_disable_comments_pages');
- //read the custom single post settings - this setting overids all of them
- $td_page = td_util::get_post_meta_array($post->ID, 'td_page');
- if (!empty($td_page['td_sidebar_position'])) {
- $loop_sidebar_position = $td_page['td_sidebar_position'];
- }
- // sidebar position used to align the breadcrumb on sidebar left + sidebar first on mobile issue
- $td_sidebar_position = '';
- if($loop_sidebar_position == 'sidebar_left') {
- $td_sidebar_position = 'td-sidebar-left';
- }
- // check if buddypress is active
- $is_buddypress_template = function_exists( 'is_buddypress' ) ? is_buddypress() : false;
- /**
- * detect the page builder
- */
- $td_use_page_builder = td_global::is_page_builder_content();
- if ($td_use_page_builder) {
- // the page is rendered using the page builder template (no sidebars)
- if (have_posts()) { ?>
- <?php while ( have_posts() ) : the_post(); ?>
- <div class="td-main-content-wrap td-main-page-wrap td-container-wrap">
- <div class="<?php if (!td_util::tdc_is_installed()) { echo 'td-container '; } ?>tdc-content-wrap">
- <?php the_content(); ?>
- </div>
- <?php
- if($td_enable_or_disable_page_comments == 'show_comments') {
- ?>
- <div class="td-container">
- <div class="td-pb-row">
- <div class="td-pb-span12">
- <?php comments_template('', true); ?>
- </div>
- </div>
- </div>
- <?php
- }
- ?>
- </div> <!-- /.td-main-content-wrap -->
- <?php endwhile; ?>
- <?php }
- } else {
- //no page builder detected, we load a default page template with sidebar / no sidebar
- ?>
- <div class="td-main-content-wrap td-container-wrap">
- <div class="td-container tdc-content-wrap <?php echo $td_sidebar_position; ?>">
- <div class="td-crumb-container">
- <?php echo td_page_generator::get_page_breadcrumbs(get_the_title()); ?>
- </div>
- <div class="td-pb-row">
- <?php
- switch ($loop_sidebar_position) {
- default:
- ?>
- <div class="td-pb-span8 td-main-content" role="main">
- <div class="td-ss-main-content">
- <?php
- if (have_posts()) {
- while ( have_posts() ) : the_post();
- ?>
- <div class="td-page-header">
- <h1 class="entry-title td-page-title">
- <span><?php the_title() ?></span>
- </h1>
- </div>
- <div class="td-page-content">
- <?php
- the_content();
- endwhile;//end loop
- }
- ?>
- </div>
- <?php
- //Display comments when we are not on buddypress template; when buddypress is true do nothing
- if ($is_buddypress_template === false) {
- if($td_enable_or_disable_page_comments == 'show_comments') {
- comments_template('', true);
- }
- } ?>
- </div>
- </div>
- <div class="td-pb-span4 td-main-sidebar" role="complementary">
- <div class="td-ss-main-sidebar">
- <?php get_sidebar(); ?>
- </div>
- </div>
- <?php
- break;
- case 'sidebar_left':
- ?>
- <div class="td-pb-span8 td-main-content <?php echo $td_sidebar_position; ?>-content" role="main">
- <div class="td-ss-main-content">
- <?php
- if (have_posts()) {
- while ( have_posts() ) : the_post();
- ?>
- <div class="td-page-header">
- <h1 class="entry-title td-page-title">
- <span><?php the_title() ?></span>
- </h1>
- </div>
- <div class="td-page-content">
- <?php
- the_content();
- endwhile; //end loop
- }
- ?>
- </div>
- <?php
- //Display comments when we are not on buddypress template; when buddypress is true do nothing
- if ($is_buddypress_template === false) {
- if($td_enable_or_disable_page_comments == 'show_comments') {
- comments_template('', true);
- }
- } ?>
- </div>
- </div>
- <div class="td-pb-span4 td-main-sidebar" role="complementary">
- <div class="td-ss-main-sidebar">
- <?php get_sidebar(); ?>
- </div>
- </div>
- <?php
- break;
- case 'no_sidebar':
- ?>
- <div class="td-pb-span12 td-main-content" role="main">
- <?php
- if (have_posts()) {
- while ( have_posts() ) : the_post();
- ?>
- <div class="td-page-header">
- <h1 class="entry-title td-page-title">
- <span><?php the_title() ?></span>
- </h1>
- </div>
- <div class="td-page-content">
- <?php
- the_content();
- endwhile; //end loop
- }
- ?>
- </div>
- <?php
- //Display comments when we are not on buddypress template; when buddypress is true do nothing
- if ($is_buddypress_template === false) {
- if($td_enable_or_disable_page_comments == 'show_comments') {
- comments_template('', true);
- }
- } ?>
- </div>
- <?php
- break;
- }
- ?>
- </div> <!-- /.td-pb-row -->
- </div> <!-- /.td-container -->
- </div> <!-- /.td-main-content-wrap -->
- <?php
- }
- ?>
- </div><!--close td-outer-wrap-->
- <?php wp_footer(); ?>
- </body>
- </html>
Advertisement
Add Comment
Please, Sign In to add comment