Anton | настройка checkout
This commit is contained in:
@@ -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(); ?>>
|
||||
|
||||
Reference in New Issue
Block a user