| 1 |
<?php |
| 2 |
/** |
| 3 |
* Single campaign template (classic themes). |
| 4 |
* |
| 5 |
* Renders the campaign page — the title plus the seeded block content — without |
| 6 |
* the theme's single-post chrome (author/category byline and the theme-injected |
| 7 |
* featured image, which the page's own cover block already provides). |
| 8 |
* |
| 9 |
* Block themes are handled separately via register_block_template(); a PHP |
| 10 |
* template cannot reproduce a block theme's header/footer/layout canvas. |
| 11 |
* |
| 12 |
* @package SureDonation |
| 13 |
*/ |
| 14 |
|
| 15 |
if ( ! defined( 'ABSPATH' ) ) { |
| 16 |
exit; // Exit if accessed directly. |
| 17 |
} |
| 18 |
|
| 19 |
// Ensure the campaign block styles are present even if the page has no blocks. |
| 20 |
wp_enqueue_style( 'suredonation-campaign-blocks' ); |
| 21 |
|
| 22 |
get_header(); |
| 23 |
?> |
| 24 |
|
| 25 |
<main class="suredonation-campaign-page"> |
| 26 |
<?php |
| 27 |
while ( have_posts() ) : |
| 28 |
the_post(); |
| 29 |
the_title( '<h1 class="suredonation-campaign-page__title">', '</h1>' ); |
| 30 |
the_content(); |
| 31 |
endwhile; |
| 32 |
?> |
| 33 |
</main> |
| 34 |
|
| 35 |
<?php |
| 36 |
get_footer(); |
| 37 |
|