shkola/wp-content/themes/dekart/page-elementary-school.php
2026-10-08 16:59:02 +00:00

176 lines
7.8 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
?>
<?php
get_header();
$post_id = get_the_ID();
$page_breadcrumbs = carbon_get_post_meta($post_id, 'page_breadcrumbs');
?>
<main class="page-elementary-school">
<?php get_template_part('template-parts/school/hero'); ?>
<?php get_template_part('template-parts/school/classes-nav'); ?>
<?php get_template_part('template-parts/school/advantages'); ?>
<?php get_template_part('template-parts/school/open-day'); ?>
<?php get_template_part('template-parts/school/personal-plan'); ?>
<?php get_template_part('template-parts/school/program'); ?>
<?php get_template_part('template-parts/school/solve-problems'); ?>
<?php get_template_part('template-parts/school/adaptation'); ?>
<?php get_template_part('template-parts/school/safety'); ?>
<?php get_template_part('template-parts/cta-consultation'); ?>
<?php get_template_part('template-parts/school/comparison-table'); ?>
<?php get_template_part('template-parts/school/accent-cta'); ?>
<?php get_template_part('template-parts/school/guarantees'); ?>
<?php get_template_part('template-parts/school/results'); ?>
<?php get_template_part('template-parts/school/gallery'); ?>
<?php get_template_part('template-parts/price-front'); ?>
<?php get_template_part('template-parts/school/enrollment-steps'); ?>
<?php get_template_part('template-parts/teachers-cards'); ?>
<?php get_template_part('template-parts/reviews-link'); ?>
<?php get_template_part('template-parts/block-foto'); ?>
<?php get_template_part('template-parts/school/faq'); ?>
<?php get_template_part('template-parts/school/readiness-check'); ?>
<?php get_template_part('template-parts/school/family-classes'); ?>
<?php get_template_part('template-parts/school/final-cta'); ?>
<?php get_template_part('template-parts/contacts'); ?>
<?php get_template_part('template-parts/sticky-cta'); ?>
</main>
<?php
$school_published = get_the_date('c', $post_id);
$school_modified = get_the_modified_time('c', $post_id);
$branch_name = get_option('branch_name') ?: carbon_get_theme_option('site_name') ?: '';
$branch_city = get_option('branch_city') ?: carbon_get_theme_option('site_city') ?: '';
$branch_city_prep = get_option('branch_city_prep') ?: ( $branch_city ? 'в ' . $branch_city : '' );
$branch_region = get_option('branch_region') ?: carbon_get_theme_option('site_region') ?: '';
$branch_address = get_option('branch_address') ?: carbon_get_theme_option('site_address') ?: '';
$branch_zip = get_option('branch_postal_code') ?: get_option('branch_zip') ?: carbon_get_theme_option('site_index') ?: '';
$branch_phone = get_option('branch_phone') ?: carbon_get_theme_option('site_phone') ?: '';
$branch_price_range = trim((string) get_option('branch_price_range'));
if (preg_match('/^\$+$/', $branch_price_range)) {
$branch_price_range = '';
}
$branch_coords = get_option('branch_coords');
$branch_lat = '';
$branch_lng = '';
if (is_string($branch_coords) && strpos($branch_coords, ',') !== false) {
$__c = array_map('trim', explode(',', $branch_coords, 2));
$branch_lat = $__c[0] ?? '';
$branch_lng = $__c[1] ?? '';
unset($__c);
}
$branch_hours_json = function_exists('dekart_schema_opening_hours')
? wp_json_encode(dekart_schema_opening_hours(), JSON_UNESCAPED_UNICODE | JSON_UNESCAPED_SLASHES)
: '[]';
$branch_schema_desc = get_option('branch_schema_description') ?: get_option('branch_description_schema') ?: '';
?>
<script type="application/ld+json">
{
"@context": "https://schema.org",
"@graph": [
{
"@type": "WebPage",
"@id": "<?php echo esc_url(untrailingslashit(home_url())); ?>/nachalnaya-shkola/",
"url": "<?php echo esc_url(untrailingslashit(home_url())); ?>/nachalnaya-shkola/",
"name": "Начальная школа «<?php echo esc_html($branch_name); ?>»<?php echo $branch_city_prep ? ' ' . esc_html($branch_city_prep) : ''; ?>",
"isPartOf": {"@id": "<?php echo esc_url(untrailingslashit(home_url())); ?>/#website"},
"datePublished": "<?php echo esc_attr($school_published); ?>",
"dateModified": "<?php echo esc_attr($school_modified); ?>",
"description": "<?php echo esc_attr($branch_schema_desc ?: sprintf('Начальная школа «%s»%s: английский с 1 класса, малокомплектные классы.', $branch_name, $branch_city_prep ? ' ' . $branch_city_prep : '')); ?>",
"breadcrumb": {"@id": "<?php echo esc_url(untrailingslashit(home_url())); ?>/nachalnaya-shkola/#breadcrumb"},
"inLanguage": "ru-RU",
"potentialAction": [
{
"@type": "ReadAction",
"target": ["<?php echo esc_url(untrailingslashit(home_url())); ?>/nachalnaya-shkola/"]
}
]
},
{
"@type": "BreadcrumbList",
"@id": "<?php echo esc_url(untrailingslashit(home_url())); ?>/nachalnaya-shkola/#breadcrumb",
"itemListElement": [
{
"@type": "ListItem",
"position": 1,
"name": "Главная страница",
"item": "<?php echo esc_url(untrailingslashit(home_url())); ?>/"
},
{
"@type": "ListItem",
"position": 2,
"name": "Начальная школа"
}
]
},
{
"@type": "WebSite",
"@id": "<?php echo esc_url(untrailingslashit(home_url())); ?>/#website",
"url": "<?php echo esc_url(untrailingslashit(home_url())); ?>/",
"name": "Частная школа «<?php echo esc_html($branch_name); ?>»",
"description": "<?php echo esc_attr(trim('Частная школа «' . $branch_name . '»' . ( $branch_city_prep ? ' ' . $branch_city_prep : '' ))); ?>",
"publisher": {"@id": "<?php echo esc_url(untrailingslashit(home_url())); ?>/#organization"},
"inLanguage": "ru-RU"
},
{
"@type": ["School", "LocalBusiness"],
"@id": "<?php echo esc_url(untrailingslashit(home_url())); ?>/#organization",
"name": "Начальная школа «<?php echo esc_html($branch_name); ?>»<?php echo $branch_city_prep ? ' ' . esc_html($branch_city_prep) : ''; ?>",
"description": "<?php echo esc_attr($branch_schema_desc ?: sprintf('Лицензированная начальная школа%s. Малокомплектные классы, английский с 1 класса, продлёнка.', $branch_city_prep ? ' ' . $branch_city_prep : '')); ?>",
"url": "<?php echo esc_url(untrailingslashit(home_url())); ?>/nachalnaya-shkola/",
"logo": "<?php echo esc_url(untrailingslashit(home_url())); ?>/wp-content/uploads/2025/04/2-1-1.jpg",
"image": "<?php echo esc_url(untrailingslashit(home_url())); ?>/wp-content/uploads/2023/05/logo-dekart.png",
"telephone": "<?php echo esc_attr($branch_phone); ?>",
"address": {
"@type": "PostalAddress",
"streetAddress": "<?php echo esc_attr($branch_address); ?>",
"addressLocality": "<?php echo esc_attr($branch_city); ?>",
"addressRegion": "<?php echo esc_attr($branch_region); ?>",
"postalCode": "<?php echo esc_attr($branch_zip); ?>",
"addressCountry": "RU"
},
"geo": {
"@type": "GeoCoordinates",
"latitude": "<?php echo esc_attr($branch_lat); ?>",
"longitude": "<?php echo esc_attr($branch_lng); ?>"
},
"openingHoursSpecification": <?php echo $branch_hours_json; ?>,
<?php if ($branch_price_range) : ?>
"priceRange": "<?php echo esc_attr($branch_price_range); ?>",
<?php endif; ?>
"knowsAbout": ["Начальное общее образование", "Начальная школа", "Начальные классы", "Подготовка к школе", "Ментальная арифметика", "Английский язык для детей"],
"isAccessibleForFree": "false"
}
]
}
</script>
<?php
get_footer();