File: /www/wwwroot/pulitocucito.it/wp-content/themes/laundry/page.php
<?php
/**
* The template for displaying all pages.
*
* This is the template that displays all pages by default.
* Please note that this is the WordPress construct of pages
* and that other 'pages' on your WordPress site may use a
* different template.
*
* @link https://codex.wordpress.org/Template_Hierarchy
*
* @package Laundry
*/
get_header();
$laundry_opt = laundry_get_options();
$theme = isset( $laundry_opt['laundry_demo_select'] ) ? $laundry_opt['laundry_demo_select'] : 1;
$page_spacing = get_post_meta( get_the_ID(), 'framework_page_spacing', true );
$left_bg = get_post_meta( get_the_ID(), 'framework_left_bg', true );
$right_bg = get_post_meta( get_the_ID(), 'framework_right_bg', true );
$bg_image_position = get_post_meta( get_the_ID(), 'framework_bg_image_position', '1' );
$left_bg = wp_get_attachment_image_url( $left_bg, 'full' );
$right_bg = wp_get_attachment_image_url( $right_bg, 'full' );
if ( $page_spacing != 'off' ) {
$page_spacing = 'section-inner';
$page_container = 'container container-fluid-lg';
} else {
$page_spacing = '';
$page_container = '';
}
if ( $theme == '2' ) { ?>
<div class="<?php echo esc_attr( $page_spacing ); ?> lazyload subpage-bg-left subpage-bg__position0<?php echo esc_attr( $bg_image_position ); ?>" data-bg="<?php echo esc_url( $left_bg ); ?>">
<div class="lazyload subpage-bg-right subpage-bg__position0<?php echo esc_attr( $bg_image_position ); ?>" data-bg="<?php echo esc_url( $right_bg ); ?>">
<div class="<?php echo esc_attr( $page_container ); ?>">
<div class="page page_sidebar_none">
<?php
while ( have_posts() ) :
the_post();
the_content();
// If comments are open or we have at least one comment, load up the comment template.
if ( comments_open() || get_comments_number() ) :
comments_template();
endif;
endwhile; // End of the loop.
?>
</div>
</div>
</div>
</div>
<?php } else { ?>
<div class="container page page_sidebar_none">
<?php
while ( have_posts() ) :
the_post();
get_template_part( 'template-parts/content', 'page' );
// If comments are open or we have at least one comment, load up the comment template.
if ( comments_open() || get_comments_number() ) :
comments_template();
endif;
endwhile; // End of the loop.
?>
</div><!-- #primary -->
<?php
}
get_footer();