Anton | настройка checkout
This commit is contained in:
@@ -15,38 +15,11 @@
|
||||
</head>
|
||||
<body <?php body_class( 'test1-cart-page' ); ?>>
|
||||
<?php wp_body_open(); ?>
|
||||
<div class="premium-topline">
|
||||
<div class="container premium-topline-inner">
|
||||
<span><?php esc_html_e( 'Корзина с товарами', 'twentytwentyfour' ); ?></span>
|
||||
<span><?php esc_html_e( 'Проверьте заказ перед оформлением доставки воды', 'twentytwentyfour' ); ?></span>
|
||||
</div>
|
||||
</div>
|
||||
<header class="site-header">
|
||||
<div class="container">
|
||||
<div class="header-row">
|
||||
<a class="brand" href="<?php echo esc_url( home_url( '/test1/' ) ); ?>" aria-label="Вернуться на страницу test1">
|
||||
<span class="brand-mark" aria-hidden="true">
|
||||
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||
<path d="M12 2C9 6.1 6 9.4 6 13.2C6 16.9 8.69 20 12 20C15.31 20 18 16.9 18 13.2C18 9.4 15 6.1 12 2Z" fill="currentColor"/>
|
||||
</svg>
|
||||
</span>
|
||||
<span class="brand-text">
|
||||
<strong><?php bloginfo( 'name' ); ?></strong>
|
||||
<span><?php esc_html_e( 'Корзина', 'twentytwentyfour' ); ?></span>
|
||||
</span>
|
||||
</a>
|
||||
|
||||
<div class="header-actions">
|
||||
<?php if ( function_exists( 'wc_get_checkout_url' ) ) : ?>
|
||||
<a class="button checkout-back-link" href="<?php echo esc_url( wc_get_checkout_url() ); ?>"><?php esc_html_e( 'Перейти к оформлению', 'twentytwentyfour' ); ?></a>
|
||||
<?php endif; ?>
|
||||
<a class="header-phone" href="tel:+79781234567">
|
||||
<span aria-hidden="true">+7 (978) 123-45-67</span>
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</header>
|
||||
<?php
|
||||
$test1_header_action_url = function_exists( 'wc_get_checkout_url' ) ? wc_get_checkout_url() : '';
|
||||
$test1_header_action_label = 'Оформление';
|
||||
require get_theme_file_path( 'template-parts/test1-shared-header.php' );
|
||||
?>
|
||||
|
||||
<main id="top">
|
||||
<section class="hero checkout-hero">
|
||||
@@ -107,52 +80,7 @@
|
||||
</div>
|
||||
</section>
|
||||
</main>
|
||||
<footer class="footer premium-footer">
|
||||
<div class="container">
|
||||
<div class="footer-grid premium-footer-grid">
|
||||
<div class="footer-card premium-footer-card premium-footer-brand">
|
||||
<a class="brand" href="<?php echo esc_url( home_url( '/test1/' ) ); ?>" aria-label="Вернуться на страницу test1">
|
||||
<span class="brand-mark" aria-hidden="true">
|
||||
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||
<path d="M12 2C9 6.1 6 9.4 6 13.2C6 16.9 8.69 20 12 20C15.31 20 18 16.9 18 13.2C18 9.4 15 6.1 12 2Z" fill="currentColor"/>
|
||||
</svg>
|
||||
</span>
|
||||
<span class="brand-text">
|
||||
<strong><?php bloginfo( 'name' ); ?></strong>
|
||||
<span><?php esc_html_e( 'Корзина в премиальном стиле test1', 'twentytwentyfour' ); ?></span>
|
||||
</span>
|
||||
</a>
|
||||
<p class="footer-description"><?php esc_html_e( 'Корзина для заказа воды в Севастополе помогает быстро проверить выбранные товары перед оформлением доставки. Здесь можно обновить заказ, скорректировать количество бутылей и перейти к следующему шагу без лишних действий.', 'twentytwentyfour' ); ?></p>
|
||||
<div class="premium-footer-pills">
|
||||
<span class="chip"><?php esc_html_e( 'мягкая премиальная палитра', 'twentytwentyfour' ); ?></span>
|
||||
<span class="chip"><?php esc_html_e( 'единый UX путь', 'twentytwentyfour' ); ?></span>
|
||||
</div>
|
||||
</div>
|
||||
<div class="footer-card premium-footer-card">
|
||||
<h3><?php esc_html_e( 'Переходы', 'twentytwentyfour' ); ?></h3>
|
||||
<div class="footer-links">
|
||||
<a href="<?php echo esc_url( home_url( '/test1/' ) ); ?>"><?php esc_html_e( 'Страница test1', 'twentytwentyfour' ); ?></a>
|
||||
<a href="<?php echo esc_url( home_url( '/test1/#catalog' ) ); ?>"><?php esc_html_e( 'Каталог', 'twentytwentyfour' ); ?></a>
|
||||
<?php if ( function_exists( 'wc_get_checkout_url' ) ) : ?>
|
||||
<a href="<?php echo esc_url( wc_get_checkout_url() ); ?>"><?php esc_html_e( 'Оформление заказа', 'twentytwentyfour' ); ?></a>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="footer-card premium-footer-card">
|
||||
<h3><?php esc_html_e( 'Контакты', 'twentytwentyfour' ); ?></h3>
|
||||
<ul class="contact-list premium-footer-contacts">
|
||||
<li><strong><?php esc_html_e( 'Телефон:', 'twentytwentyfour' ); ?></strong> <a href="tel:+79781234567">+7 (978) 123-45-67</a></li>
|
||||
<li><strong><?php esc_html_e( 'E-mail:', 'twentytwentyfour' ); ?></strong> order@aqualinia-sev.ru</li>
|
||||
<li><strong><?php esc_html_e( 'Поддержка:', 'twentytwentyfour' ); ?></strong> <?php esc_html_e( 'ежедневно с 8:00 до 21:00', 'twentytwentyfour' ); ?></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<div class="footer-bottom premium-footer-bottom">
|
||||
<span>© 2026 <?php bloginfo( 'name' ); ?></span>
|
||||
<span><?php esc_html_e( 'Корзина с водой для дома и офиса: быстрый переход к оформлению доставки.', 'twentytwentyfour' ); ?></span>
|
||||
</div>
|
||||
</div>
|
||||
</footer>
|
||||
<?php require get_theme_file_path( 'template-parts/test1-shared-footer.php' ); ?>
|
||||
<?php wp_footer(); ?>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
@@ -15,38 +15,11 @@
|
||||
</head>
|
||||
<body <?php body_class( 'test1-checkout-page' ); ?>>
|
||||
<?php wp_body_open(); ?>
|
||||
<div class="premium-topline">
|
||||
<div class="container premium-topline-inner">
|
||||
<span><?php esc_html_e( 'Оформление заказа воды', 'twentytwentyfour' ); ?></span>
|
||||
<span><?php esc_html_e( 'Доставка воды по Севастополю для дома и офиса', 'twentytwentyfour' ); ?></span>
|
||||
</div>
|
||||
</div>
|
||||
<header class="site-header">
|
||||
<div class="container">
|
||||
<div class="header-row">
|
||||
<a class="brand" href="<?php echo esc_url( home_url( '/test1/' ) ); ?>" aria-label="Вернуться на страницу test1">
|
||||
<span class="brand-mark" aria-hidden="true">
|
||||
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||
<path d="M12 2C9 6.1 6 9.4 6 13.2C6 16.9 8.69 20 12 20C15.31 20 18 16.9 18 13.2C18 9.4 15 6.1 12 2Z" fill="currentColor"/>
|
||||
</svg>
|
||||
</span>
|
||||
<span class="brand-text">
|
||||
<strong><?php bloginfo( 'name' ); ?></strong>
|
||||
<span><?php esc_html_e( 'Оформление заказа', 'twentytwentyfour' ); ?></span>
|
||||
</span>
|
||||
</a>
|
||||
|
||||
<div class="header-actions">
|
||||
<?php if ( function_exists( 'wc_get_cart_url' ) ) : ?>
|
||||
<a class="ghost-button checkout-back-link" href="<?php echo esc_url( wc_get_cart_url() ); ?>"><?php esc_html_e( 'Вернуться в корзину', 'twentytwentyfour' ); ?></a>
|
||||
<?php endif; ?>
|
||||
<a class="header-phone" href="tel:+79781234567">
|
||||
<span aria-hidden="true">+7 (978) 123-45-67</span>
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</header>
|
||||
<?php
|
||||
$test1_header_action_url = function_exists( 'wc_get_cart_url' ) ? wc_get_cart_url() : '';
|
||||
$test1_header_action_label = 'Корзина';
|
||||
require get_theme_file_path( 'template-parts/test1-shared-header.php' );
|
||||
?>
|
||||
|
||||
<main id="top">
|
||||
<section class="hero checkout-hero">
|
||||
@@ -74,7 +47,7 @@
|
||||
<div class="glass-card checkout-card premium-form-card">
|
||||
<?php
|
||||
while ( have_posts() ) :
|
||||
|
||||
the_post();
|
||||
the_content();
|
||||
endwhile;
|
||||
?>
|
||||
@@ -91,55 +64,7 @@
|
||||
</div>
|
||||
</section>
|
||||
</main>
|
||||
<footer class="footer premium-footer">
|
||||
<div class="container">
|
||||
<div class="footer-grid premium-footer-grid">
|
||||
<div class="footer-card premium-footer-card premium-footer-brand">
|
||||
<a class="brand" href="<?php echo esc_url( home_url( '/test1/' ) ); ?>" aria-label="Вернуться на страницу test1">
|
||||
<span class="brand-mark" aria-hidden="true">
|
||||
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||
<path d="M12 2C9 6.1 6 9.4 6 13.2C6 16.9 8.69 20 12 20C15.31 20 18 16.9 18 13.2C18 9.4 15 6.1 12 2Z" fill="currentColor"/>
|
||||
</svg>
|
||||
</span>
|
||||
<span class="brand-text">
|
||||
<strong><?php bloginfo( 'name' ); ?></strong>
|
||||
<span><?php esc_html_e( 'Премиальная доставка воды по Севастополю', 'twentytwentyfour' ); ?></span>
|
||||
</span>
|
||||
</a>
|
||||
<p class="footer-description"><?php esc_html_e( 'Финальный экран заказа оформлен в едином языке с landing test1: мягкий люкс, чистая структура и уверенная конверсионная логика без визуального шума.', 'twentytwentyfour' ); ?></p>
|
||||
<p class="footer-description"><?php esc_html_e( 'Оформление заказа на доставку воды в Севастополе для дома и офиса. Закажите воду 19 литров, питьевую и минеральную воду онлайн с быстрым подтверждением и удобным временем доставки.', 'twentytwentyfour' ); ?></p>
|
||||
<div class="premium-footer-pills">
|
||||
<span class="chip"><?php esc_html_e( 'ежедневно 8:00-21:00', 'twentytwentyfour' ); ?></span>
|
||||
<span class="chip"><?php esc_html_e( 'подъем на этаж', 'twentytwentyfour' ); ?></span>
|
||||
</div>
|
||||
</div>
|
||||
<div class="footer-card premium-footer-card">
|
||||
<h3><?php esc_html_e( 'Переходы', 'twentytwentyfour' ); ?></h3>
|
||||
<div class="footer-links">
|
||||
<a href="<?php echo esc_url( home_url( '/test1/' ) ); ?>"><?php esc_html_e( 'Страница test1', 'twentytwentyfour' ); ?></a>
|
||||
<?php if ( function_exists( 'wc_get_cart_url' ) ) : ?>
|
||||
<a href="<?php echo esc_url( wc_get_cart_url() ); ?>"><?php esc_html_e( 'Корзина', 'twentytwentyfour' ); ?></a>
|
||||
<?php endif; ?>
|
||||
<?php if ( function_exists( 'wc_get_checkout_url' ) ) : ?>
|
||||
<a href="<?php echo esc_url( wc_get_checkout_url() ); ?>"><?php esc_html_e( 'Оформление заказа', 'twentytwentyfour' ); ?></a>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="footer-card premium-footer-card">
|
||||
<h3><?php esc_html_e( 'Контакты', 'twentytwentyfour' ); ?></h3>
|
||||
<ul class="contact-list premium-footer-contacts">
|
||||
<li><strong><?php esc_html_e( 'Телефон:', 'twentytwentyfour' ); ?></strong> <a href="tel:+79781234567">+7 (978) 123-45-67</a></li>
|
||||
<li><strong><?php esc_html_e( 'E-mail:', 'twentytwentyfour' ); ?></strong> order@aqualinia-sev.ru</li>
|
||||
<li><strong><?php esc_html_e( 'Маршрут:', 'twentytwentyfour' ); ?></strong> <?php esc_html_e( 'Гагаринский, Ленинский, Нахимовский, Балаклава', 'twentytwentyfour' ); ?></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<div class="footer-bottom premium-footer-bottom">
|
||||
<span>© 2026 <?php bloginfo( 'name' ); ?></span>
|
||||
<span><?php esc_html_e( 'Доставка воды в Севастополе: оформление заказа онлайн за несколько минут.', 'twentytwentyfour' ); ?></span>
|
||||
</div>
|
||||
</div>
|
||||
</footer>
|
||||
<?php require get_theme_file_path( 'template-parts/test1-shared-footer.php' ); ?>
|
||||
<?php wp_footer(); ?>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
@@ -88,6 +88,15 @@ $landing_html = file_exists( $landing_file ) ? file_get_contents( $landing_file
|
||||
if ( $landing_html ) {
|
||||
$catalog_markup = twentytwentyfour_test1_catalog_markup();
|
||||
|
||||
ob_start();
|
||||
$test1_header_mode = 'cart';
|
||||
require get_theme_file_path( 'template-parts/test1-shared-header.php' );
|
||||
$shared_header_markup = (string) ob_get_clean();
|
||||
|
||||
ob_start();
|
||||
require get_theme_file_path( 'template-parts/test1-shared-footer.php' );
|
||||
$shared_footer_markup = (string) ob_get_clean();
|
||||
|
||||
if ( '' !== $catalog_markup ) {
|
||||
$catalog_static_markup = <<<'HTML'
|
||||
<div class="catalog-grid">
|
||||
@@ -155,6 +164,9 @@ HTML;
|
||||
|
||||
$landing_html = str_replace( $catalog_static_markup, $catalog_markup, $landing_html );
|
||||
}
|
||||
|
||||
$landing_html = preg_replace( '/<header class="site-header">.*?<\/header>/is', $shared_header_markup, $landing_html, 1 );
|
||||
$landing_html = preg_replace( '/<footer class="footer">.*?<\/footer>/is', $shared_footer_markup, $landing_html, 1 );
|
||||
}
|
||||
?><!DOCTYPE html>
|
||||
<html <?php language_attributes(); ?>>
|
||||
|
||||
@@ -0,0 +1,47 @@
|
||||
<?php
|
||||
/**
|
||||
* Shared footer for test1-related WooCommerce pages.
|
||||
*
|
||||
* @package Twenty_Twenty_Four
|
||||
*/
|
||||
|
||||
?>
|
||||
<footer class="footer premium-footer">
|
||||
<div class="container">
|
||||
<div class="footer-grid">
|
||||
<div class="footer-card">
|
||||
<a class="brand" href="<?php echo esc_url( home_url( '/test1/' ) ); ?>" aria-label="Перейти на страницу test1">
|
||||
<span class="brand-mark" aria-hidden="true">
|
||||
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||
<path d="M12 2C9 6.1 6 9.4 6 13.2C6 16.9 8.69 20 12 20C15.31 20 18 16.9 18 13.2C18 9.4 15 6.1 12 2Z" fill="currentColor"/>
|
||||
</svg>
|
||||
</span>
|
||||
<span class="brand-text">
|
||||
<strong>АкваЛиния</strong>
|
||||
<span>вода с доставкой для Севастополя</span>
|
||||
</span>
|
||||
</a>
|
||||
<p class="footer-description">Доставка воды в Севастополе для дома, офиса, кафе и фитнес-клубов. Вода 19 литров, питьевая и минеральная вода с удобным заказом на сайте.</p>
|
||||
</div>
|
||||
<div class="footer-card">
|
||||
<h3>Навигация и документы</h3>
|
||||
<div class="footer-links">
|
||||
<a href="<?php echo esc_url( home_url( '/test1/#catalog' ) ); ?>">Каталог</a>
|
||||
<a href="<?php echo esc_url( home_url( '/test1/#delivery' ) ); ?>">Доставка воды в Севастополе</a>
|
||||
<a href="<?php echo esc_url( home_url( '/test1/#business' ) ); ?>">Доставка воды в офис</a>
|
||||
<a href="<?php echo esc_url( home_url( '/test1/#faq' ) ); ?>">Частые вопросы</a>
|
||||
<a href="<?php echo esc_url( home_url( '/test1/#contacts' ) ); ?>">Контакты</a>
|
||||
</div>
|
||||
<div class="footer-legal">
|
||||
<a href="#">Политика конфиденциальности</a>
|
||||
<a href="#">Пользовательское соглашение</a>
|
||||
<a href="#">Условия использования</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="footer-bottom">
|
||||
<span>© 2026 АкваЛиния. Все права защищены.</span>
|
||||
<span>Сделано для запросов «заказать воду на дом» и «вода 19 литров с доставкой»</span>
|
||||
</div>
|
||||
</div>
|
||||
</footer>
|
||||
@@ -0,0 +1,76 @@
|
||||
<?php
|
||||
/**
|
||||
* Shared header for test1-related WooCommerce pages.
|
||||
*
|
||||
* @package Twenty_Twenty_Four
|
||||
*/
|
||||
|
||||
$test1_header_action_url = isset( $test1_header_action_url ) ? $test1_header_action_url : '';
|
||||
$test1_header_action_label = isset( $test1_header_action_label ) ? $test1_header_action_label : '';
|
||||
$test1_header_mode = isset( $test1_header_mode ) ? $test1_header_mode : 'link';
|
||||
?>
|
||||
<header class="site-header">
|
||||
<div class="container">
|
||||
<div class="header-row">
|
||||
<a class="brand" href="<?php echo esc_url( home_url( '/test1/' ) ); ?>" aria-label="Перейти на страницу test1">
|
||||
<span class="brand-mark" aria-hidden="true">
|
||||
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||
<path d="M12 2C9 6.1 6 9.4 6 13.2C6 16.9 8.69 20 12 20C15.31 20 18 16.9 18 13.2C18 9.4 15 6.1 12 2Z" fill="currentColor"/>
|
||||
</svg>
|
||||
</span>
|
||||
<span class="brand-text">
|
||||
<strong>АкваЛиния</strong>
|
||||
<span>доставка воды в Севастополе</span>
|
||||
</span>
|
||||
</a>
|
||||
|
||||
<nav class="nav" aria-label="Основная навигация">
|
||||
<a href="<?php echo esc_url( home_url( '/test1/#catalog' ) ); ?>">Каталог</a>
|
||||
<a href="<?php echo esc_url( home_url( '/test1/#delivery' ) ); ?>">Доставка</a>
|
||||
<a href="<?php echo esc_url( home_url( '/test1/#business' ) ); ?>">Для дома и офиса</a>
|
||||
<a href="<?php echo esc_url( home_url( '/test1/#faq' ) ); ?>">FAQ</a>
|
||||
<a href="<?php echo esc_url( home_url( '/test1/#contacts' ) ); ?>">Контакты</a>
|
||||
</nav>
|
||||
|
||||
<div class="header-actions">
|
||||
<a class="header-phone" href="tel:+79781234567">
|
||||
<span aria-hidden="true">+7 (978) 123-45-67</span>
|
||||
</a>
|
||||
<?php if ( 'cart' === $test1_header_mode ) : ?>
|
||||
<button class="cart-button" id="cartOpenButton" aria-label="Открыть корзину">
|
||||
<span aria-hidden="true">Корзина</span>
|
||||
<span class="cart-count" id="cartCount">0</span>
|
||||
</button>
|
||||
<button class="mobile-toggle" id="mobileToggle" aria-label="Открыть меню" aria-expanded="false" aria-controls="mobilePanel">
|
||||
<svg width="20" height="20" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg" aria-hidden="true">
|
||||
<path d="M4 7H20" stroke="currentColor" stroke-width="2" stroke-linecap="round"/>
|
||||
<path d="M4 12H20" stroke="currentColor" stroke-width="2" stroke-linecap="round"/>
|
||||
<path d="M4 17H20" stroke="currentColor" stroke-width="2" stroke-linecap="round"/>
|
||||
</svg>
|
||||
</button>
|
||||
<?php elseif ( $test1_header_action_url && $test1_header_action_label ) : ?>
|
||||
<a class="cart-button checkout-back-link" href="<?php echo esc_url( $test1_header_action_url ); ?>"><span><?php echo esc_html( $test1_header_action_label ); ?></span></a>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<?php if ( 'cart' === $test1_header_mode ) : ?>
|
||||
<div class="mobile-panel" id="mobilePanel">
|
||||
<div class="mobile-card">
|
||||
<nav class="mobile-nav" aria-label="Мобильная навигация">
|
||||
<a href="#catalog">Каталог</a>
|
||||
<a href="#delivery">Условия доставки</a>
|
||||
<a href="#business">Для дома и офиса</a>
|
||||
<a href="#faq">FAQ</a>
|
||||
<a href="#contacts">Контакты</a>
|
||||
</nav>
|
||||
<a class="header-phone" href="tel:+79781234567">+7 (978) 123-45-67</a>
|
||||
<button class="cart-button" id="mobileCartOpenButton" aria-label="Открыть корзину с мобильного меню">
|
||||
<span>Корзина</span>
|
||||
<span class="cart-count" id="mobileCartCount">0</span>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
</header>
|
||||
Reference in New Issue
Block a user