From 8a83e62905b2ecb997b459384f4deda1f17d1ce2 Mon Sep 17 00:00:00 2001 From: Joshua T Flowers Date: Tue, 10 Mar 2020 10:14:18 +0100 Subject: [PATCH] Use full width template for homepage in stores using Storefront (https://github.com/woocommerce/woocommerce-admin/pull/3846) --- plugins/woocommerce-admin/src/API/OnboardingTasks.php | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/plugins/woocommerce-admin/src/API/OnboardingTasks.php b/plugins/woocommerce-admin/src/API/OnboardingTasks.php index 8c4c2db5b31..0aa0a9aefc0 100644 --- a/plugins/woocommerce-admin/src/API/OnboardingTasks.php +++ b/plugins/woocommerce-admin/src/API/OnboardingTasks.php @@ -427,6 +427,11 @@ class OnboardingTasks extends \WC_REST_Data_Controller { update_option( 'page_on_front', $post_id ); update_option( 'woocommerce_onboarding_homepage_post_id', $post_id ); + // Use the full width template on stores using Storefront. + if ( 'storefront' === get_stylesheet() ) { + update_post_meta( $post_id, '_wp_page_template', 'template-fullwidth.php' ); + } + return array( 'status' => 'success', 'message' => __( 'Homepage created.', 'woocommerce-admin' ),