Files
eventLabs/templates/front.php
2026-11-11 21:30:20 -05:00

50 lines
1.0 KiB
PHP

<?php
use BurnEvents\Calendar;
use BurnEvents\Events;
defined( 'ABSPATH' ) || exit;
$block_theme = wp_is_block_theme();
if ( $block_theme ) :
// Block assets must be registered before the theme prints its import map.
ob_start();
block_template_part( 'header' );
$header = ob_get_clean();
ob_start();
block_template_part( 'footer' );
$footer = ob_get_clean();
?>
<!doctype html>
<html <?php language_attributes(); ?>>
<head>
<meta charset="<?php bloginfo( 'charset' ); ?>">
<meta name="viewport" content="width=device-width, initial-scale=1">
<?php wp_head(); ?>
</head>
<body <?php body_class(); ?>>
<?php wp_body_open(); ?>
<div class="wp-site-blocks">
<?php echo $header; ?>
<?php
else :
get_header();
endif;
?>
<main id="primary" class="be-page">
<?php echo Calendar::content(); ?>
<?php if ( is_singular( Events::EVENT ) && ( comments_open() || get_comments_number() ) ) { comments_template(); } ?>
</main>
<?php
if ( $block_theme ) :
echo $footer;
?>
</div>
<?php wp_footer(); ?>
</body>
</html>
<?php
else :
get_footer();
endif;