2026-08-07 11:52:31 +00:00

33 lines
1.7 KiB
PHP
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<?php
// ─── Почему частная школа (CF school_why_private_*) ───
if (! defined('ABSPATH')) {
exit;
}
$post_id = get_the_ID();
$why_private_title = crb_get_post_meta($post_id, 'school_why_private_title', 'Почему начальная частная школа «Декарт», а не государственная?');
$why_private_text = crb_get_post_meta($post_id, 'school_why_private_text');
$why_private_photo = crb_get_post_meta($post_id, 'school_why_private_photo');
$why_private_src = $why_private_photo ? wp_get_attachment_url((int) $why_private_photo) : (get_template_directory_uri() . '/assets/images/666-1.webp');
?>
<section class="info__block info__block-right reveal">
<div class="container">
<div class="info__block-wrapper">
<div class="info__block-content">
<div class="info__block-content_text">
<h2 class="bento-h2"><?php echo esc_html($why_private_title); ?></h2>
<?php
if ($why_private_text) {
echo wp_kses_post($why_private_text);
} else {
echo wp_kses_post(crb_get_post_meta($post_id, 'block_text_2'));
}
?>
</div>
<div class="info__block-content_img">
<img loading="lazy" width="273.37" height="285" src="<?php echo esc_url($why_private_src); ?>" alt="Ученик начальной частной школы Декарт за учебой — почему школа лучше государственной">
</div>
</div>
</div>
</div>
</section>