<?php
get_header();
if ( 1 == 1 ) {
echo '<div class="wp-site-blocks">';
echo preg_replace('!</[^>]+>!', '', do_blocks('<!-- wp:template-part {"slug":"header","tagName":"header", "align":"full", "className":""} /-->'));
block_template_part( 'header' );
echo '</header>';
echo '<main class="alignfull is-layout-constrained">';
echo preg_replace('!</[^>]+>!', '', do_blocks( '<!-- wp:template-part {"slug":"post-content","tagName":"div", "align":"full", "className":"article-wrapper"} /-->'));
block_template_part( 'post' );
echo '</div>';
print('</main>' );
echo preg_replace('!</[^>]+>!', '', do_blocks( '<!-- wp:template-part {"slug":"footer", "tagName":"footer", "align":"full", "className":""} /-->'));
block_template_part( 'footer' );
print('</footer>' );
print('</div>' );
} else {
echo preg_replace('!</[^>]+>!', '', do_blocks('<!-- wp:template-part {"slug":"header","tagName":"header", "align":"full", "className":""} /-->'));
block_template_part( 'header' );
echo '</header>';
if ( have_posts() ) {
echo '<main class="alignfull is-layout-constrained">';
while ( have_posts() ) {
the_post();
echo preg_replace('!</[^>]+>!', '', do_blocks( '<!-- wp:template-part {"slug":"post-content","tagName":"div", "align":"full", "className":"article-wrapper"} /-->'));
echo '<article class="wp-block-group alignfull post is-layout-constrained">';
if( has_post_thumbnail() ) {
echo '<figure class="wp-block-post-featured-image">';
the_post_thumbnail('post-thumbnail');
echo '</figure>';
}
echo preg_replace('!</[^>]+>!', '', do_blocks('<!-- wp:template-part {"slug":"header","tagName":"header", "align":"full", "className":""} /-->'));
the_title( '<h2>', '</h2>' );
echo '</header>';
print('<div class="is-layout-constrained alignfull wp-block-post-content">' );
the_content();
print('</div>' );
print('</article>' );
}
print('</main>' );
}
echo preg_replace('!</[^>]+>!', '', do_blocks( '<!-- wp:template-part {"slug":"footer", "tagName":"footer", "align":"full", "className":""} /-->'));
block_template_part( 'footer' );
echo '</footer>';
}
get_footer();